15b8bc0c17aae0dc6af0bab05f68fd07c0015885
[platform/core/uifw/at-spi2-atk.git] / cspi / spi-roletypes.h
1 /*
2  * AT-SPI - Assistive Technology Service Provider Interface
3  * (Gnome Accessibility Project; http://developer.gnome.org/projects/gap)
4  *
5  * Copyright 2001, 2002 Sun Microsystems Inc.,
6  * Copyright 2001, 2002 Ximian, Inc.
7  *
8  * This library is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU Library General Public
10  * License as published by the Free Software Foundation; either
11  * version 2 of the License, or (at your option) any later version.
12  *
13  * This library is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16  * Library General Public License for more details.
17  *
18  * You should have received a copy of the GNU Library General Public
19  * License along with this library; if not, write to the
20  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
21  * Boston, MA 02111-1307, USA.
22  */
23
24 #ifndef _SPI_ROLETYPES_H_
25 #define _SPI_ROLETYPES_H_
26
27 #ifdef  __cplusplus
28 extern "C" {
29 #endif
30
31 /**
32  * AccessibleRole:
33  * @SPI_ROLE_INVALID: role is not legal, something is wrong with this object
34  * @SPI_ROLE_ACCEL_LABEL: object is a label indicating keyboard
35  *                              accelerators for the parent
36  * @SPI_ROLE_ALERT: Object is used to alert the user about something
37  * @SPI_ROLE_ANIMATION: Object contains a dynamic or moving image
38  * @SPI_ROLE_ARROW: Object is a 2d directional indicator
39  * @SPI_ROLE_CALENDAR: Object contains one or more dates, usually arranged into
40  *                     a 2d list
41  * @SPI_ROLE_CANVAS: Object that can be drawn into and is used to trap events
42  * @SPI_ROLE_CHECK_BOX: Object representd a choice that can be checked or unchecked
43  *                    and provides a separate indicator for the current state.
44  * @SPI_ROLE_CHECK_MENU_ITEM: Object is a menu item that behaves like a CHECK_BOX
45  * @SPI_ROLE_COLOR_CHOOSER: A specialized dialog that lets the user choose a color.
46  * @SPI_ROLE_COLUMN_HEADER: The header for a column of data 
47  * @SPI_ROLE_COMBO_BOX: A list of choices the user can select from
48  * @SPI_ROLE_DATE_EDITOR: Allows entry of a date
49  * @SPI_ROLE_DESKTOP_ICON: An inconifed internal frame within a DESKTOP_PANE
50  * @SPI_ROLE_DESKTOP_FRAME: A pane that supports internal frames and
51  *              iconified versions of those internal frames.
52  * @SPI_ROLE_DIAL: A rotating/rotatable valuator
53  * @SPI_ROLE_DIALOG: A top level window with title bar and a border
54  * @SPI_ROLE_DIRECTORY_PANE: A pane that allows the user to navigate
55  *              through and select the contents of a directory.
56  * @SPI_ROLE_DRAWING_AREA: An object used for drawing custom user interface elements
57  * @SPI_ROLE_FILE_CHOOSER: A specialized dialog that displays the files in the
58  *               directory and lets the user select a file, browse a different
59  *               directory, or specify a filename.
60  * @SPI_ROLE_FILLER: A object that fills up space in a user interface
61  * @SPI_ROLE_FONT_CHOOSER: Allows selection of a display font
62  * @SPI_ROLE_FRAME: A top level window with a title bar, border, menubar, etc.
63  * @SPI_ROLE_GLASS_PANE: A pane that is guaranteed to be painted on top of all
64  *               panes beneath it
65  * @SPI_ROLE_HTML_CONTAINER: A document container for HTML, whose children
66  *               represent the document content.
67  * @SPI_ROLE_ICON: A small fixed size picture, typically used to decorate components.
68  * @SPI_ROLE_IMAGE: An image, typically static
69  * @SPI_ROLE_INTERNAL_FRAME: A frame-like object that is clipped by a desktop pane.
70  * @SPI_ROLE_LABEL: An object used to present an icon or short string in an interface
71  * @SPI_ROLE_LAYERED_PANE: A specialized pane that allows its children to be drawn in layers
72  *                         providing a  form of stacking order.
73  * @SPI_ROLE_LIST: An object that presents a list of objects to the user and allows the
74  *                         user to select one or more of them.
75  * @SPI_ROLE_LIST_ITEM: An object that represents an element of a list.
76  * @SPI_ROLE_MENU: An object usually found inside a menu bar that contains a list of
77  *                 actions the user can choose from.
78  * @SPI_ROLE_MENU_BAR: An object usually drawn at the top of the primary dialog box of an
79  *                 application that contains a list of menus the user can choose from.
80  * @SPI_ROLE_MENU_ITEM: An object usually contained in a menu that presents an
81  *                 action the user can choose.
82  * @SPI_ROLE_OPTION_PANE: A specialized pane whose primary use is inside a DIALOG 
83  * @SPI_ROLE_PAGE_TAB: An object that is a child of a page tab list
84  * @SPI_ROLE_PAGE_TAB_LIST: An object that presents a series of panels (or page tabs),
85  *        one at a time, through some mechanism provided by the object.
86  * @SPI_ROLE_PANEL: A generic container that is often used to group objects.
87  * @SPI_ROLE_PASSWORD_TEXT: A text object uses for passwords, or other places where
88  *        the text content is not shown visibly to the user.
89  * @SPI_ROLE_POPUP_MENU: A temporary window that is usually used to offer the user a
90  *        list of choices, and then hides when the user selects one of those choices.
91  * @SPI_ROLE_PROGRESS_BAR: An object used to indicate how much of a task has been completed.
92  * @SPI_ROLE_PUSH_BUTTON: A specialized object which the user can interact with to tell
93  *        the application to do something.
94  * @SPI_ROLE_RADIO_BUTTON: A specialized check box that will cause other radio buttons in the
95  *        same group to become uncghecked when this one is checked.
96  * @SPI_ROLE_RADIO_MENU_ITEM: A specialized menu item that behaves like a 
97  *        radio button.
98  * @SPI_ROLE_ROOT_PANE: A specialized pane that has a glass pane and a layered pane as its
99  *        children.
100  * @SPI_ROLE_ROW_HEADER: The header for a row of data
101  * @SPI_ROLE_SCROLL_BAR: An object usually used to allow a user to incrementally
102  *        view a large amount of data.
103  * @SPI_ROLE_SCROLL_PANE: An object that allows a user to incrementally view a large amount
104  *         of information.
105  * @SPI_ROLE_SEPARATOR: An object usually contained in a menu to provide a visible and
106  *        logical separation of the contents in a menu.
107  * @SPI_ROLE_SLIDER: An object that allows the user to select from a bounded range.
108  * @SPI_ROLE_SPIN_BUTTON: An object which allows selection from a set of choices and
109  *                        displays the current choice.
110  * @SPI_ROLE_SPLIT_PANE: A specialized panel that presents two other panels at the same time.
111  * @SPI_ROLE_STATUS_BAR: An object the display qualitative status information. c.f. PROGRESS_BAR
112  * @SPI_ROLE_TABLE: An object used to rpesent information in terms of rows and columns.
113  * @SPI_ROLE_TABLE_CELL: An object which is a descendant of a table,
114  *        with a row/column location.  A cell may span multiple rows and columns.
115  * @SPI_ROLE_TABLE_COLUMN_HEADER: An object which serves to describe a column in a table.
116  * @SPI_ROLE_TABLE_ROW_HEADER: An object which serves to label or describe a row in a table.
117  * @SPI_ROLE_TEAROFF_MENU_ITEM: A menu item which allows the menu to be removed from
118  *                              a menubar and placed in its own window
119  * @SPI_ROLE_TERMINAL: An object that emulates a teletype or terminal
120  * @SPI_ROLE_TEXT: An object that presents text to the user
121  * @SPI_ROLE_TOGGLE_BUTTON: A specialized push button that can be checked or unchecked,
122  *        but does not provide a separate indicator for the current state.
123  * @SPI_ROLE_TOOL_BAR: A bar or palette usually composed of push buttons or toggle buttons
124  * @SPI_ROLE_TOOL_TIP: An object that provides information about another object
125  * @SPI_ROLE_TREE: An object used to represent hierarchical information to the user
126  * @SPI_ROLE_TREE_TABLE: An object which represents both hierarchical and tabular information
127  * @SPI_ROLE_UNKNOWN: The object contains some SpiAccessible information, but its role is
128  *                    not known.
129  * @SPI_ROLE_VIEWPORT: An object usually used in a scroll pane, which restricts the visual
130  *                    area into which its contents are presented.
131  * @SPI_ROLE_WINDOW: A top level window with no title or border.
132  * @SPI_ROLE_EXTENDED: This object's role is not included in the standard role list and
133  *                     should be queried by name.
134  * @SPI_ROLE_HEADER: An object that serves as a document header.
135  * @SPI_ROLE_FOOTER: An object that serves as a document footer.
136  * @SPI_ROLE_PARAGRAPH: An object which is contains a paragraph of text content.
137  * @SPI_ROLE_RULER: An object which describes margins and tab stops, etc.  for text objects 
138  *                  which it controls (should have CONTROLLER_FOR relation to such). 
139  * @SPI_ROLE_APPLICATION: An object which corresponds to a desktop application,
140  *                  which may have children of @SPI_ROLE_FRAME or other type.
141  * @SPI_ROLE_AUTOCOMPLETE: The object is a dialog or list containing items for 
142  *                         insertion into an entry widget, for instance a list 
143  *                          of words for completion of a text entry.
144  * @SPI_ROLE_EDITBAR: The object is an editable text object in a toolbar
145  * @SPI_ROLE_EMBEDDED: The object is an embedded component container.  
146  *                     This role is a  "grouping" hint that the contained 
147  *                     objects share a context which is different from the 
148  *                     container in which this accessible is embedded.
149  *                     Uses: document embedding, "panel applets", etc.
150  * @SPI_ROLE_ENTRY: The object is a component whose textual content may be entered or modified by the user, provided @SPI_STATE_EDITABLE is present.
151  * @SPI_ROLE_CHART: The object is a graphical depiction of quantitative data. It may contain multiple subelements whose attributes and/or description may be queried to obtain both the quantitative data and information about how the data is being presented. The LABELLED_BY relation is particularly important in interpreting objects of this type, as is the accessible-description property.
152  * @SPI_ROLE_CAPTION: The object contains descriptive information, usually textual, about another user interface element such as a table, chart, or image.
153  * @SPI_ROLE_DOCUMENT_FRAME: The object is a visual frame or container which contains a view of document content. Document frames may occur within another Document instance, in which case the second document may be said to be embedded in the containing instance. HTML frames are often ROLE_DOCUMENT_FRAME. Either this object, or a singleton descendant, should implement the Document interface.
154  * @SPI_ROLE_HEADING: The object serves as a heading for content which follows it in a document. The 'heading level' of the heading, if availabe, may be obtained by querying the object's attributes.
155  * @SPI_ROLE_PAGE: The object is a containing instance which encapsulates a page of information. @SPI_ROLE_PAGE is used in documents and content which support a paginated navigation model.
156  * @SPI_ROLE_SECTION: The object is a containing instance of document content which constitutes a particular 'logical' section of the document. The type of content within a section, and the nature of the section division itself, may be obtained by querying the object's attributes. Sections may be nested.
157  * @SPI_ROLE_REDUNDANT_OBJECT: The object is redundant with another object in the hierarchy, and is exposed for purely technical reasons.  Objects of this role should normally be ignored by clients. 
158  * @SPI_ROLE_FORM: The object is a container for form controls, for instance as part of a 
159  * web form or user-input form within a document.  This role is primarily a tag/convenience for 
160  * clients when navigating complex documents, it is not expected that ordinary GUI containers will 
161  * always have ATK_ROLE_FORM.
162  * @SPI_ROLE_LINK: The object is a hypertext anchor.
163  * @SPI_ROLE_INPUT_METHOD_WINDOW: The object is an input method window used
164  * to input or compose a text character (typically a "complex text" character).
165  * @SPI_ROLE_LAST_DEFINED: Used to determine the end of the role enumeration.
166  *
167  * Describes the role of an object
168  *
169  * These are the built-in enumerated roles that UI components can have.
170  * Other roles may be added at runtime, so an AccessibleRole >=
171  * SPI_ROLE_LAST_DEFINED is not necessarily an error.
172  **/
173 typedef enum
174 {
175   SPI_ROLE_INVALID,
176   SPI_ROLE_ACCEL_LABEL,
177   SPI_ROLE_ALERT,
178   SPI_ROLE_ANIMATION,
179   SPI_ROLE_ARROW,
180   SPI_ROLE_CALENDAR,
181   SPI_ROLE_CANVAS,
182   SPI_ROLE_CHECK_BOX,
183   SPI_ROLE_CHECK_MENU_ITEM,
184   SPI_ROLE_COLOR_CHOOSER,
185   SPI_ROLE_COLUMN_HEADER,
186   SPI_ROLE_COMBO_BOX,
187   SPI_ROLE_DATE_EDITOR,
188   SPI_ROLE_DESKTOP_ICON,
189   SPI_ROLE_DESKTOP_FRAME,
190   SPI_ROLE_DIAL,
191   SPI_ROLE_DIALOG,
192   SPI_ROLE_DIRECTORY_PANE,
193   SPI_ROLE_DRAWING_AREA,
194   SPI_ROLE_FILE_CHOOSER,
195   SPI_ROLE_FILLER,
196   SPI_ROLE_FONT_CHOOSER,
197   SPI_ROLE_FRAME,
198   SPI_ROLE_GLASS_PANE,
199   SPI_ROLE_HTML_CONTAINER,
200   SPI_ROLE_ICON,
201   SPI_ROLE_IMAGE,
202   SPI_ROLE_INTERNAL_FRAME,
203   SPI_ROLE_LABEL,
204   SPI_ROLE_LAYERED_PANE,
205   SPI_ROLE_LIST,
206   SPI_ROLE_LIST_ITEM,
207   SPI_ROLE_MENU,
208   SPI_ROLE_MENU_BAR,
209   SPI_ROLE_MENU_ITEM,
210   SPI_ROLE_OPTION_PANE,
211   SPI_ROLE_PAGE_TAB,
212   SPI_ROLE_PAGE_TAB_LIST,
213   SPI_ROLE_PANEL,
214   SPI_ROLE_PASSWORD_TEXT,
215   SPI_ROLE_POPUP_MENU,
216   SPI_ROLE_PROGRESS_BAR,
217   SPI_ROLE_PUSH_BUTTON,
218   SPI_ROLE_RADIO_BUTTON,
219   SPI_ROLE_RADIO_MENU_ITEM,
220   SPI_ROLE_ROOT_PANE,
221   SPI_ROLE_ROW_HEADER,
222   SPI_ROLE_SCROLL_BAR,
223   SPI_ROLE_SCROLL_PANE,
224   SPI_ROLE_SEPARATOR,
225   SPI_ROLE_SLIDER,
226   SPI_ROLE_SPIN_BUTTON,
227   SPI_ROLE_SPLIT_PANE,
228   SPI_ROLE_STATUS_BAR,
229   SPI_ROLE_TABLE,
230   SPI_ROLE_TABLE_CELL,
231   SPI_ROLE_TABLE_COLUMN_HEADER,
232   SPI_ROLE_TABLE_ROW_HEADER,
233   SPI_ROLE_TEAROFF_MENU_ITEM,
234   SPI_ROLE_TERMINAL,
235   SPI_ROLE_TEXT,
236   SPI_ROLE_TOGGLE_BUTTON,
237   SPI_ROLE_TOOL_BAR,
238   SPI_ROLE_TOOL_TIP,
239   SPI_ROLE_TREE,
240   SPI_ROLE_TREE_TABLE,
241   SPI_ROLE_UNKNOWN,
242   SPI_ROLE_VIEWPORT,
243   SPI_ROLE_WINDOW,
244   SPI_ROLE_EXTENDED,
245   SPI_ROLE_HEADER,
246   SPI_ROLE_FOOTER,
247   SPI_ROLE_PARAGRAPH,
248   SPI_ROLE_RULER,
249   SPI_ROLE_APPLICATION,
250   SPI_ROLE_AUTOCOMPLETE,
251   SPI_ROLE_EDITBAR,
252   SPI_ROLE_EMBEDDED,
253   SPI_ROLE_ENTRY,
254   SPI_ROLE_CHART,
255   SPI_ROLE_CAPTION,
256   SPI_ROLE_DOCUMENT_FRAME,
257   SPI_ROLE_HEADING,
258   SPI_ROLE_PAGE,
259   SPI_ROLE_SECTION,
260   SPI_ROLE_FORM,
261   SPI_ROLE_REDUNDANT_OBJECT,
262   SPI_ROLE_LINK,
263   SPI_ROLE_INPUT_METHOD_WINDOW,
264   SPI_ROLE_LAST_DEFINED
265 } AccessibleRole;
266
267 char* AccessibleRole_getName (AccessibleRole role);
268
269 #ifdef  __cplusplus
270 }
271 #endif
272
273 #endif