Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(78)

Side by Side Diff: third_party/iaccessible2/ia2_api_all.idl

Issue 1989009: Revert 46842 - Reimplement accessibility of web content by caching the entire... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/renderer/render_view.cc ('k') | third_party/iaccessible2/iaccessible2.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 /*************************************************************************
2 *
3 * File Name (IA2CommonTypes.idl)
4 *
5 * IAccessible2 IDL Specification
6 *
7 * Copyright (c) Linux Foundation 2007, 2009
8 * Copyright (c) IBM Corp. 2006
9 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
10 *
11 * This library is free software; you can redistribute it and/or
12 * modify it under the terms of the GNU Lesser General Public
13 * License version 2.1, as published by the Free Software Foundation; either
14 * version 2.1 of the License, or (at your option) any later version.
15 *
16 * This library is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 * Lesser General Public License for more details.
20 *
21 * You should have received a copy of the GNU Lesser General Public
22 * License along with this library; if not, write to the Free Software
23 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 U SA
24 *
25 ************************************************************************/
26
27 /** These constants control the scrolling of an object or substring into a windo w.
28
29 This enum is used in IAccessible2::scrollTo and IAccessibleText::scrollSubstrin gTo.
30 */
31 enum IA2ScrollType {
32
33 /** Scroll the top left corner of the object or substring such that the top le ft
34 corner (and as much as possible of the rest of the object or substring) is wi thin
35 the top level window. In cases where the entire object or substring fits wit hin
36 the top level window, the placement of the object or substring is dependent o n
37 the application. For example, the object or substring may be scrolled to the
38 closest edge, the furthest edge, or midway between those two edges. In cases
39 where there is a hierarchy of nested scrollable controls, more than one contr ol
40 may have to be scrolled.
41 */
42 IA2_SCROLL_TYPE_TOP_LEFT,
43
44 /** Scroll the bottom right corner of the object or substring such that the bo ttom right
45 corner (and as much as possible of the rest of the object or substring) is wi thin
46 the top level window. In cases where the entire object or substring fits wit hin
47 the top level window, the placement of the object or substring is dependent o n
48 the application. For example, the object or substring may be scrolled to the
49 closest edge, the furthest edge, or midway between those two edges. In cases
50 where there is a hierarchy of nested scrollable controls, more than one contr ol
51 may have to be scrolled.
52 */
53 IA2_SCROLL_TYPE_BOTTOM_RIGHT,
54
55 /** Scroll the top edge of the object or substring such that the top edge
56 (and as much as possible of the rest of the object or substring) is within th e
57 top level window. In cases where the entire object or substring fits within
58 the top level window, the placement of the object or substring is dependent o n
59 the application. For example, the object or substring may be scrolled to the
60 closest edge, the furthest edge, or midway between those two edges. In cases
61 where there is a hierarchy of nested scrollable controls, more than one contr ol
62 may have to be scrolled.
63 */
64 IA2_SCROLL_TYPE_TOP_EDGE,
65
66 /** Scroll the bottom edge of the object or substring such that the bottom edg e
67 (and as much as possible of the rest of the object or substring) is within th e
68 top level window. In cases where the entire object or substring fits within
69 the top level window, the placement of the object or substring is dependent o n
70 the application. For example, the object or substring may be scrolled to the
71 closest edge, the furthest edge, or midway between those two edges. In cases
72 where there is a hierarchy of nested scrollable controls, more than one contr ol
73 may have to be scrolled.
74 */
75 IA2_SCROLL_TYPE_BOTTOM_EDGE,
76
77 /** Scroll the left edge of the object or substring such that the left edge
78 (and as much as possible of the rest of the object or substring) is within th e
79 top level window. In cases where the entire object or substring fits within
80 the top level window, the placement of the object or substring is dependent o n
81 the application. For example, the object or substring may be scrolled to the
82 closest edge, the furthest edge, or midway between those two edges. In cases
83 where there is a hierarchy of nested scrollable controls, more than one contr ol
84 may have to be scrolled.
85 */
86 IA2_SCROLL_TYPE_LEFT_EDGE,
87
88 /** Scroll the right edge of the object or substring such that the right edge
89 (and as much as possible of the rest of the object or substring) is within th e
90 top level window. In cases where the entire object or substring fits within
91 the top level window, the placement of the object or substring is dependent o n
92 the application. For example, the object or substring may be scrolled to the
93 closest edge, the furthest edge, or midway between those two edges. In cases
94 where there is a hierarchy of nested scrollable controls, more than one contr ol
95 may have to be scrolled.
96 */
97 IA2_SCROLL_TYPE_RIGHT_EDGE,
98
99 /** Scroll the object or substring such that as much as possible of the
100 object or substring is within the top level window. The placement of
101 the object is dependent on the application. For example, the object or
102 substring may be scrolled to to closest edge, the furthest edge, or midway
103 between those two edges.
104 */
105 IA2_SCROLL_TYPE_ANYWHERE
106 };
107
108 /** These constants define which coordinate system a point is located in.
109
110 This enum is used in IAccessible2::scrollToPoint, IAccessibleImage::imagePositi on,
111 IAccessibleText::characterExtents, and IAccessibleText::offsetAtPoint, and
112 IAccessibleText::scrollSubstringToPoint.
113 */
114 enum IA2CoordinateType {
115
116 /// The coordinates are relative to the screen.
117 IA2_COORDTYPE_SCREEN_RELATIVE,
118
119 /** The coordinates are relative to the upper left corner of the bounding box
120 of the immediate parent.
121 */
122 IA2_COORDTYPE_PARENT_RELATIVE
123
124 };
125
126 /** Special offsets for use in IAccessibleText and IAccessibleEditableText metho ds
127
128 Refer to @ref _specialOffsets
129 "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Me thods"
130 for more information.
131 */
132 enum IA2TextSpecialOffsets {
133 IA2_TEXT_OFFSET_LENGTH = -1, /**< This offset is equivalent to the length of the string. It eliminates
134 the need to cal l IAccessibleText::nCharacters. */
135 IA2_TEXT_OFFSET_CARET = -2 /**< This offset signifies that the text related to the physical location
136 of the caret sh ould be used. */
137 };
138
139 /** These constants specify the kind of change made to a table.
140
141 This enum is used in the IA2TableModelChange struct which in turn is used by
142 IAccessibleTable::modelChange and IAccessibleTable2::modelChange.
143 */
144 enum IA2TableModelChangeType {
145 IA2_TABLE_MODEL_CHANGE_INSERT, // = 0;
146 IA2_TABLE_MODEL_CHANGE_DELETE,
147 IA2_TABLE_MODEL_CHANGE_UPDATE
148 };
149
150 /** A structure defining the type of and extents of changes made to a table
151
152 IAccessibleTable::modelChange and IAccessibleTable2::modelChange return this st ruct.
153 In the case of an insertion or change the row and column offsets define the bou ndaries
154 of the inserted or changed subtable after the operation. In the case of a dele tion
155 the row and column offsets define the boundaries of the subtable being removed before
156 the removal.
157 */
158 typedef struct IA2TableModelChange {
159 enum IA2TableModelChangeType type; // insert, delete, update
160 long firstRow; ///< 0 based, inclusive
161 long lastRow; ///< 0 based, inclusive
162 long firstColumn; ///< 0 based, inclusive
163 long lastColumn; ///< 0 based, inclusive
164 } IA2TableModelChange;
165 /*************************************************************************
166 *
167 * File Name (AccessibleRelation.idl)
168 *
169 * IAccessible2 IDL Specification
170 *
171 * Copyright (c) Linux Foundation 2007, 2009
172 * Copyright (c) IBM Corp. 2006
173 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
174 *
175 * This library is free software; you can redistribute it and/or
176 * modify it under the terms of the GNU Lesser General Public
177 * License version 2.1, as published by the Free Software Foundation; either
178 * version 2.1 of the License, or (at your option) any later version.
179 *
180 * This library is distributed in the hope that it will be useful,
181 * but WITHOUT ANY WARRANTY; without even the implied warranty of
182 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
183 * Lesser General Public License for more details.
184 *
185 * You should have received a copy of the GNU Lesser General Public
186 * License along with this library; if not, write to the Free Software
187 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 U SA
188 *
189 ************************************************************************/
190
191 import "objidl.idl";
192 import "oaidl.idl";
193 import "oleacc.idl";
194
195 /** @defgroup grpRelations Relations
196 Use the following constants to compare against the BSTRs returned by
197 IAccessibleRelation::relationType.
198 */
199 ///@{
200
201 /** Some attribute of this object is affected by a target object. */
202 const WCHAR *const IA2_RELATION_CONTROLLED_BY = L"controlledBy";
203
204 /** This object is interactive and controls some attribute of a target object. * /
205 const WCHAR *const IA2_RELATION_CONTROLLER_FOR = L"controllerFor";
206
207 /** This object is described by the target object. */
208 const WCHAR *const IA2_RELATION_DESCRIBED_BY = L"describedBy";
209
210 /** This object is describes the target object. */
211 const WCHAR *const IA2_RELATION_DESCRIPTION_FOR = L"descriptionFor";
212
213 /** This object is embedded by a target object. */
214 const WCHAR *const IA2_RELATION_EMBEDDED_BY = L"embeddedBy";
215
216 /** This object embeds a target object. This relation can be used on the
217 OBJID_CLIENT accessible for a top level window to show where the content
218 areas are.
219 */
220 const WCHAR *const IA2_RELATION_EMBEDS = L"embeds";
221
222 /** Content flows to this object from a target object.
223 This relation and IA2_RELATION_FLOWS_TO are useful to tie text and non-text
224 objects together in order to allow assistive technology to follow the
225 intended reading order.
226 */
227 const WCHAR *const IA2_RELATION_FLOWS_FROM = L"flowsFrom";
228
229 /** Content flows from this object to a target object. */
230 const WCHAR *const IA2_RELATION_FLOWS_TO = L"flowsTo";
231
232 /** This object is label for a target object. */
233 const WCHAR *const IA2_RELATION_LABEL_FOR = L"labelFor";
234
235 /** This object is labelled by a target object. Note that the double L spelling
236 which follows is preferred. Please use it instead. This single L version may
237 be removed in a later version.
238 */
239 const WCHAR *const IA2_RELATION_LABELED_BY = L"labelledBy";
240
241 /** This object is labelled by a target object. */
242 const WCHAR *const IA2_RELATION_LABELLED_BY = L"labelledBy";
243
244 /** This object is a member of a group of one or more objects. When
245 there is more than one object in the group each member may have one and the
246 same target, e.g. a grouping object. It is also possible that each member has
247 multiple additional targets, e.g. one for every other member in the group.
248 */
249 const WCHAR *const IA2_RELATION_MEMBER_OF = L"memberOf";
250
251 /** This object is a child of a target object. */
252 const WCHAR *const IA2_RELATION_NODE_CHILD_OF = L"nodeChildOf";
253
254 /** This object is a parent window of the target object. */
255 const WCHAR *const IA2_RELATION_PARENT_WINDOW_OF = L"parentWindowOf";
256
257 /** This object is a transient component related to the target object.
258 When this object is activated the target object doesn't loose focus.
259 */
260 const WCHAR *const IA2_RELATION_POPUP_FOR = L"popupFor";
261
262 /** This object is a sub window of a target object. */
263 const WCHAR *const IA2_RELATION_SUBWINDOW_OF = L"subwindowOf";
264
265 ///@}
266
267 /// This interface gives access to an object's set of relations.
268 [object, uuid(7CDF86EE-C3DA-496a-BDA4-281B336E1FDC)]
269 interface IAccessibleRelation : IUnknown
270 {
271 /** @brief Returns the type of the relation.
272 @param [out] relationType
273 The strings returned are defined @ref grpRelations "in this section of the d ocumentation".
274 @retval S_OK
275 */
276 [propget] HRESULT relationType
277 (
278 [out, retval] BSTR *relationType
279 );
280
281 /** @brief Returns a localized version of the relation type.
282 @param [out] localizedRelationType
283 @retval S_OK
284 */
285 [propget] HRESULT localizedRelationType
286 (
287 [out, retval] BSTR *localizedRelationType
288 );
289
290 /** @brief Returns the number of targets for this relation.
291 @param [out] nTargets
292 @retval S_OK
293 */
294 [propget] HRESULT nTargets
295 (
296 [out, retval] long *nTargets
297 );
298
299 /** @brief Returns one accessible relation target.
300 @param [in] targetIndex
301 0 based index
302 @param [out] target
303 @retval S_OK
304 @retval S_FALSE if there is nothing to return, [out] value is NULL
305 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
306 @note Use QueryInterface to get IAccessible2.
307 */
308 [propget] HRESULT target
309 (
310 [in] long targetIndex,
311 [out, retval] IUnknown **target
312 );
313
314 /** @brief Returns multiple accessible relation targets
315 @param [in] maxTargets
316 maximum size of the array allocated by the client
317 @param [out] targets
318 The array of target objects. Note that this array is to be allocated by the
319 client and freed when no longer needed. Refer to @ref _arrayConsiderati on
320 "Special Consideration when using Arrays" for more details. You will ne ed to use
321 QueryInterface on the IUnknown to get the IAccessible2.
322 @param [out] nTargets
323 actual number of targets in the returned array (not more than maxTargets )
324 @retval S_OK
325 @retval S_FALSE if there is nothing to return, nTargets is set to 0
326 */
327 [propget] HRESULT targets
328 (
329 [in] long maxTargets,
330 [out, size_is(maxTargets), length_is(*nTargets)]
331 IUnknown **targets,
332 [out, retval] long *nTargets
333 );
334
335 }
336 /*************************************************************************
337 *
338 * File Name (AccessibleAction.idl)
339 *
340 * IAccessible2 IDL Specification
341 *
342 * Copyright (c) Linux Foundation 2007, 2008
343 * Copyright (c) IBM Corp. 2006
344 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
345 *
346 * This library is free software; you can redistribute it and/or
347 * modify it under the terms of the GNU Lesser General Public
348 * License version 2.1, as published by the Free Software Foundation; either
349 * version 2.1 of the License, or (at your option) any later version.
350 *
351 * This library is distributed in the hope that it will be useful,
352 * but WITHOUT ANY WARRANTY; without even the implied warranty of
353 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
354 * Lesser General Public License for more details.
355 *
356 * You should have received a copy of the GNU Lesser General Public
357 * License along with this library; if not, write to the Free Software
358 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 U SA
359 *
360 ************************************************************************/
361
362 import "objidl.idl";
363 import "oaidl.idl";
364 import "oleacc.idl";
365
366 /** @brief This interface gives access to actions that can be executed
367 for accessible objects.
368
369 Every accessible object that can be manipulated via the native GUI beyond the
370 methods available either in the MSAA IAccessible interface or in the set of
371 IAccessible2 interfaces (other than this IAccessibleAction interface) should
372 support the IAccessibleAction interface in order to provide Assistive Technolo gy
373 access to all the actions that can be performed by the object. Each action ca n
374 be performed or queried for a name, description or associated key bindings.
375 Actions are needed more for ATs that assist the mobility impaired, such as
376 on-screen keyboards and voice command software. By providing actions directly ,
377 the AT can present them to the user without the user having to perform the ext ra
378 steps to navigate a context menu.
379
380 The first action should be equivalent to the MSAA default action. If there is
381 only one action, %IAccessibleAction should also be implemented.
382 */
383 [object, uuid(B70D9F59-3B5A-4dba-AB9E-22012F607DF5)]
384 interface IAccessibleAction : IUnknown
385 {
386
387 /** @brief Returns the number of accessible actions available in this object.
388
389 If there are more than one, the first one is considered the
390 "default" action of the object.
391 @param [out] nActions
392 The returned value of the number of actions is zero if there are
393 no actions.
394 @retval S_OK
395 @note This method is missing a [propget] prefix in the IDL. The result is th e
396 method is named nActions in generated C++ code instead of get_nActions.
397 */
398 HRESULT nActions
399 (
400 [out,retval] long* nActions
401 );
402
403 /** @brief Performs the specified Action on the object.
404 @param [in] actionIndex
405 0 based index specifying the action to perform. If it lies outside
406 the valid range no action is performed.
407 @retval S_OK
408 @retval E_INVALIDARG if bad [in] passed
409 */
410 HRESULT doAction
411 (
412 [in] long actionIndex
413 );
414
415 /** @brief Returns a description of the specified action of the object.
416 @param [in] actionIndex
417 0 based index specifying which action's description to return.
418 If it lies outside the valid range an empty string is returned.
419 @param [out] description
420 The returned value is a localized string of the specified action.
421 @retval S_OK
422 @retval S_FALSE if there is nothing to return, [out] value is NULL
423 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
424 */
425 [propget] HRESULT description
426 (
427 [in] long actionIndex,
428 [out, retval] BSTR *description
429 );
430
431 /** @brief Returns an array of BSTRs describing one or more key bindings, if
432 there are any, associated with the specified action.
433
434 The returned strings are the localized human readable key sequences to be
435 used to activate each action, e.g. "Ctrl+Shift+D". Since these key
436 sequences are to be used when the object has focus, they are like
437 mnemonics (access keys), and not like shortcut (accelerator) keys.
438
439 There is no need to implement this method for single action controls since
440 that would be redundant with the standard MSAA programming practice of
441 getting the mnemonic from get_accKeyboardShortcut.
442
443 An AT such as an On Screen Keyboard might not expose these bindings but
444 provide alternative means of activation.
445
446 Note: the client allocates and passes in an array of pointers. The server
447 allocates the BSTRs and passes back one or more pointers to these BSTRs into
448 the array of pointers allocated by the client. The client is responsible
449 for deallocating the BSTRs.
450
451 @param [in] actionIndex
452 0 based index specifying which action's key bindings should be returned.
453 @param [in] nMaxBindings
454 This parameter is ignored. Refer to @ref _arrayConsideration
455 "Special Consideration when using Arrays" for more details.
456 @param [out] keyBindings
457 An array of BSTRs, allocated by the server, one for each key binding.
458 Free it with CoTaskMemFree.
459 @param [out] nBindings
460 The number of key bindings returned; the size of the returned array.
461 @retval S_OK
462 @retval S_FALSE if there are no relations, [out] values are NULL and 0 respec tively
463 @retval E_INVALIDARG if bad [in] passed, [out] values are NULL and 0 respecti vely
464 */
465 [propget] HRESULT keyBinding
466 (
467 [in] long actionIndex,
468 [in] long nMaxBindings,
469 [out, size_is(,nMaxBindings), length_is(,*nBindings)] BSTR **keyBindings,
470 [out, retval] long *nBindings
471 );
472
473 /** @brief Returns the non-localized name of specified action.
474 @param [in] actionIndex
475 0 based index specifying which action's non-localized name should be returne d.
476 @param [out] name
477 @retval S_OK
478 @retval S_FALSE if there is nothing to return, [out] value is NULL
479 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
480 */
481 [propget] HRESULT name
482 (
483 [in] long actionIndex,
484 [out, retval] BSTR *name
485 );
486
487 /** @brief Returns the localized name of specified action.
488 @param [in] actionIndex
489 0 based index specifying which action's localized name should be returned.
490 @param [out] localizedName
491 @retval S_OK
492 @retval S_FALSE if there is nothing to return, [out] value is NULL
493 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
494 */
495 [propget] HRESULT localizedName
496 (
497 [in] long actionIndex,
498 [out, retval] BSTR *localizedName
499 );
500
501 }
502 /*************************************************************************
503 *
504 * File Name (AccessibleRole.idl)
505 *
506 * IAccessible2 IDL Specification
507 *
508 * Copyright (c) Linux Foundation 2007, 2008
509 * Copyright (c) IBM Corp. 2006
510 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
511 *
512 * This library is free software; you can redistribute it and/or
513 * modify it under the terms of the GNU Lesser General Public
514 * License version 2.1, as published by the Free Software Foundation; either
515 * version 2.1 of the License, or (at your option) any later version.
516 *
517 * This library is distributed in the hope that it will be useful,
518 * but WITHOUT ANY WARRANTY; without even the implied warranty of
519 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
520 * Lesser General Public License for more details.
521 *
522 * You should have received a copy of the GNU Lesser General Public
523 * License along with this library; if not, write to the Free Software
524 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02110-1301 USA
525 *
526 ************************************************************************/
527
528 import "objidl.idl";
529
530 /** Collection of roles
531
532 This enumerator defines an extended set of accessible roles of objects impleme nting
533 the %IAccessible2 interface. These roles are in addition to the MSAA roles obt ained
534 through the MSAA get_accRole method. Examples are 'footnote', 'heading', and
535 'label'. You obtain an object's %IAccessible2 roles by calling IAccessible2::r ole.
536 */
537 enum IA2Role {
538
539 /** Unknown role. The object contains some Accessible information, but its
540 role is not known.
541 */
542 IA2_ROLE_UNKNOWN = 0,
543
544 /** An object that can be drawn into and to manage events from the objects
545 drawn into it. Also refer to ::IA2_ROLE_FRAME,
546 ::IA2_ROLE_GLASS_PANE, and ::IA2_ROLE_LAYERED_PANE.
547 */
548 IA2_ROLE_CANVAS = 0x401,
549
550 /// A caption describing another object.
551 IA2_ROLE_CAPTION,
552
553 /// Used for check buttons that are menu items.
554 IA2_ROLE_CHECK_MENU_ITEM,
555
556 /// A specialized dialog that lets the user choose a color.
557 IA2_ROLE_COLOR_CHOOSER,
558
559 /// A date editor.
560 IA2_ROLE_DATE_EDITOR,
561
562 /** An iconified internal frame in an ::IA2_ROLE_DESKTOP_PANE.
563 Also refer to ::IA2_ROLE_INTERNAL_FRAME.
564 */
565 IA2_ROLE_DESKTOP_ICON,
566
567 /** A desktop pane. A pane that supports internal frames and iconified
568 versions of those internal frames. Also refer to ::IA2_ROLE_INTERNAL_FRAME.
569 */
570 IA2_ROLE_DESKTOP_PANE,
571
572 /** A directory pane. A pane that allows the user to navigate through
573 and select the contents of a directory. May be used by a file chooser.
574 Also refer to ::IA2_ROLE_FILE_CHOOSER.
575 */
576 IA2_ROLE_DIRECTORY_PANE,
577
578 /** An editable text object in a toolbar.
579 <BR><B>Note:</B> This role has been deprecated. The edit bar role was meant
580 for a text area in a tool bar. However, to detect a text area in a tool bar
581 the AT can query the parent.
582 */
583 IA2_ROLE_EDITBAR,
584
585 /// Embedded (OLE) object.
586 IA2_ROLE_EMBEDDED_OBJECT,
587
588 /// Text that is used as an endnote (footnote at the end of a chapter or secti on).
589 IA2_ROLE_ENDNOTE,
590
591 /** A file chooser. A specialized dialog that displays the files in the
592 directory and lets the user select a file, browse a different directory,
593 or specify a filename. May use the directory pane to show the contents of
594 a directory.
595 Also refer to ::IA2_ROLE_DIRECTORY_PANE.
596 */
597 IA2_ROLE_FILE_CHOOSER,
598
599 /** A font chooser. A font chooser is a component that lets the user pick
600 various attributes for fonts.
601 */
602 IA2_ROLE_FONT_CHOOSER,
603
604 /** Footer of a document page.
605 Also refer to ::IA2_ROLE_HEADER.
606 */
607 IA2_ROLE_FOOTER,
608
609 /// Text that is used as a footnote. Also refer to ::IA2_ROLE_ENDNOTE.
610 IA2_ROLE_FOOTNOTE,
611
612 /** A container of form controls. An example of the use of this role is to
613 represent an HTML FORM tag.
614 */
615 IA2_ROLE_FORM,
616
617 /** Frame role. A top level window with a title bar, border, menu bar, etc.
618 It is often used as the primary window for an application. Also refer to
619 ::IA2_ROLE_CANVAS and the MSAA roles of dialog and window.
620 */
621 IA2_ROLE_FRAME,
622
623 /** A glass pane. A pane that is guaranteed to be painted on top of all panes
624 beneath it. Also refer to ::IA2_ROLE_CANVAS, ::IA2_ROLE_INTERNAL_FRAME, and
625 ::IA2_ROLE_ROOT_PANE.
626 */
627 IA2_ROLE_GLASS_PANE,
628
629 /** Header of a document page.
630 Also refer to ::IA2_ROLE_FOOTER.
631 */
632 IA2_ROLE_HEADER,
633
634 /// Heading. Use the IAccessible2::attributes heading-level attribute to dete rmine the heading level.
635 IA2_ROLE_HEADING,
636
637 /// A small fixed size picture, typically used to decorate components.
638 IA2_ROLE_ICON,
639
640 /** An image map object. Usually a graphic with multiple hotspots, where
641 each hotspot can be activated resulting in the loading of another document
642 or section of a document.
643 */
644 IA2_ROLE_IMAGE_MAP,
645
646 /** An object which is used to allow input of characters not found on a keyboa rd,
647 such as the input of Chinese characters on a Western keyboard.
648 */
649 IA2_ROLE_INPUT_METHOD_WINDOW,
650
651 /** An internal frame. A frame-like object that is clipped by a desktop pane.
652 The desktop pane, internal frame, and desktop icon objects are often used to
653 create multiple document interfaces within an application.
654 Also refer to ::IA2_ROLE_DESKTOP_ICON, ::IA2_ROLE_DESKTOP_PANE, and ::IA2_ROL E_FRAME.
655 */
656 IA2_ROLE_INTERNAL_FRAME,
657
658 /// An object used to present an icon or short string in an interface.
659 IA2_ROLE_LABEL,
660
661 /** A layered pane. A specialized pane that allows its children to be drawn
662 in layers, providing a form of stacking order. This is usually the pane that
663 holds the menu bar as well as the pane that contains most of the visual
664 components in a window.
665 Also refer to ::IA2_ROLE_CANVAS, ::IA2_ROLE_GLASS_PANE, and ::IA2_ROLE_ROOT_P ANE.
666 */
667 IA2_ROLE_LAYERED_PANE,
668
669 /// An embedded note which is not visible until activated.
670 IA2_ROLE_NOTE,
671
672 /** A specialized pane whose primary use is inside a dialog.
673 Also refer to MSAA's dialog role.
674 */
675 IA2_ROLE_OPTION_PANE,
676
677 /** An object representing a page of document content. It is used in document s
678 which are accessed by the user on a page by page basis.
679 */
680 IA2_ROLE_PAGE,
681
682 /// A paragraph of text.
683 IA2_ROLE_PARAGRAPH,
684
685 /** A radio button that is a menu item.
686 Also refer to MSAA's button and menu item roles.
687 */
688 IA2_ROLE_RADIO_MENU_ITEM,
689
690 /** An object which is redundant with another object in the accessible hierarc hy.
691 ATs typically ignore objects with this role.
692 */
693 IA2_ROLE_REDUNDANT_OBJECT,
694
695 /** A root pane. A specialized pane that has a glass pane and a layered pane
696 as its children.
697 Also refer to ::IA2_ROLE_GLASS_PANE and ::IA2_ROLE_LAYERED_PANE
698 */
699 IA2_ROLE_ROOT_PANE,
700
701 /** A ruler such as those used in word processors.
702 */
703 IA2_ROLE_RULER,
704
705 /** A scroll pane. An object that allows a user to incrementally view a large
706 amount of information. Its children can include scroll bars and a viewport.
707 Also refer to ::IA2_ROLE_VIEW_PORT and MSAA's scroll bar role.
708 */
709 IA2_ROLE_SCROLL_PANE,
710
711 /** A container of document content. An example of the use of this role is to
712 represent an HTML DIV tag. A section may be used as a region. A region is a
713 group of elements that together form a perceivable unit. A region does not
714 necessarily follow the logical structure of the content, but follows the
715 perceivable structure of the page. A region may have an attribute in the set
716 of IAccessible2::attributes which indicates that it is "live". A live region
717 is content that is likely to change in response to a timed change, a user
718 event, or some other programmed logic or event.
719 */
720 IA2_ROLE_SECTION,
721
722 /// Object with graphical representation used to represent content on draw pag es.
723 IA2_ROLE_SHAPE,
724
725 /** A split pane. A specialized panel that presents two other panels at the
726 same time. Between the two panels is a divider the user can manipulate to mak e
727 one panel larger and the other panel smaller.
728 */
729 IA2_ROLE_SPLIT_PANE,
730
731 /** An object that forms part of a menu system but which can be "undocked"
732 from or "torn off" the menu system to exist as a separate window.
733 */
734 IA2_ROLE_TEAR_OFF_MENU,
735
736 /// An object used as a terminal emulator.
737 IA2_ROLE_TERMINAL,
738
739 /// Collection of objects that constitute a logical text entity.
740 IA2_ROLE_TEXT_FRAME,
741
742 /** A toggle button. A specialized push button that can be checked or unchecke d,
743 but does not provide a separate indicator for the current state.
744 Also refer to MSAA's roles of push button, check box, and radio button.
745 <BR><B>Note:</B> IA2_ROLE_TOGGLE_BUTTON should not be used. Instead, use MSA A's
746 ROLE_SYSTEM_PUSHBUTTON and STATE_SYSTEM_PRESSED.
747 */
748 IA2_ROLE_TOGGLE_BUTTON,
749
750 /** A viewport. An object usually used in a scroll pane. It represents the
751 portion of the entire data that the user can see. As the user manipulates
752 the scroll bars, the contents of the viewport can change.
753 Also refer to ::IA2_ROLE_SCROLL_PANE.
754 */
755 IA2_ROLE_VIEW_PORT
756
757 };
758 /*************************************************************************
759 *
760 * File Name (AccessibleStates.idl)
761 *
762 * IAccessible2 IDL Specification
763 *
764 * Copyright (c) Linux Foundation 2007, 2008
765 * Copyright (c) IBM Corp. 2006
766 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
767 *
768 * This library is free software; you can redistribute it and/or
769 * modify it under the terms of the GNU Lesser General Public
770 * License version 2.1, as published by the Free Software Foundation; either
771 * version 2.1 of the License, or (at your option) any later version.
772 *
773 * This library is distributed in the hope that it will be useful,
774 * but WITHOUT ANY WARRANTY; without even the implied warranty of
775 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
776 * Lesser General Public License for more details.
777 *
778 * You should have received a copy of the GNU Lesser General Public
779 * License along with this library; if not, write to the Free Software
780 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02110-1301 USA
781 *
782 ************************************************************************/
783
784 import "objidl.idl";
785
786 typedef long AccessibleStates;
787
788 /** %IAccessible2 specific state bit constants
789
790 This enum defines the state bits returned by IAccessible2::states. The
791 %IAccessible2 state bits are in addition to those returned by MSAA.
792 */
793 enum IA2States {
794
795 /** Indicates a window is currently the active window, or is an active subelemen t
796 within a container or table.
797
798 This state can be used to indicate the current active item in a container, even
799 if the container itself is not currently active. In other words this would ind icate
800 the item that will get focus if you tab to the container.
801
802 This information is important for knowing what to report for trees and potentia lly
803 other containers in a virtual buffer.
804
805 Also, see ::IA2_STATE_MANAGES_DESCENDANTS for more information.
806 */
807 IA2_STATE_ACTIVE = 0x1,
808
809 /** Indicates that the object is armed.
810
811 Used to indicate that the control is "pressed" and will be invoked when the
812 actuator, e.g. a mouse button, is "released". An AT which either monitors the
813 mouse or synthesizes mouse events might need to know that, and possibly a talk ing
814 interface would even let the user know about it. It could also potentially be
815 useful to on screen keyboards or test tools since the information does indicat e
816 something about the state of the interface, for example, code operating asynch ronously
817 might need to wait for the armed state to change before doing something else.
818
819 */
820 IA2_STATE_ARMED = 0x2,
821
822 /** Indicates the user interface object corresponding to this object no longer e xists. */
823 IA2_STATE_DEFUNCT = 0x4,
824
825 /** Indicates the user can change the contents of this object. */
826 IA2_STATE_EDITABLE = 0x8,
827
828 /** Indicates the orientation of this object is horizontal. */
829 IA2_STATE_HORIZONTAL = 0x10,
830
831 /** Indicates this object is minimized and is represented only by an icon. */
832 IA2_STATE_ICONIFIED = 0x20,
833
834 /** Indicates an input validation failure. */
835 IA2_STATE_INVALID_ENTRY = 0x40,
836
837 /** Indicates that this object manages its children.
838
839 Note: Due to the fact that MSAA's WinEvents don't allow the active child index
840 to be passed on the IA2_EVENT_ACTIVE_DESCENDANT_CHANGED event, the manages
841 descendants scheme can't be used. Instead the active child object has to fi re
842 MSAA's EVENT_OBJECT_FOCUS. In a future release a new event mechanism may be
843 added to provide for event specific data to be passed with the event. At that
844 time the IA2_EVENT_ACTIVE_DECENDENT_CHANGED event and
845 IA2_STATE_MANAGES_DESCENDANTS state would be useful.
846 */
847 IA2_STATE_MANAGES_DESCENDANTS = 0x80,
848
849 /** Indicates that an object is modal.
850
851 Modal objects have the behavior that something must be done with the object
852 before the user can interact with an object in a different window.
853 */
854 IA2_STATE_MODAL = 0x100,
855
856 /** Indicates this text object can contain multiple lines of text. */
857 IA2_STATE_MULTI_LINE = 0x200,
858
859 /** Indicates this object paints every pixel within its rectangular region. */
860 IA2_STATE_OPAQUE = 0x400,
861
862 /** Indicates that user interaction is required.
863
864 An example of when this state is used is when a field in a form must be filled
865 before a form can be processed.
866 */
867 IA2_STATE_REQUIRED = 0x800,
868
869 /** Indicates an object which supports text selection.
870
871 Note: This is different than MSAA STATE_SYSTEM_SELECTABLE.
872 */
873 IA2_STATE_SELECTABLE_TEXT = 0x1000,
874
875 /** Indicates that this text object can contain only a single line of text. */
876 IA2_STATE_SINGLE_LINE = 0x2000,
877
878 /** Indicates that the accessible object is stale.
879
880 This state is used when the accessible object no longer accurately
881 represents the state of the object which it is representing such as when an
882 object is transient or when an object has been or is in the process of being
883 destroyed or when the object's index in its parent has changed.
884 */
885 IA2_STATE_STALE = 0x4000,
886
887 /** Indicates that the object implements autocompletion.
888
889 This state indicates that a text control will respond to the input of
890 one ore more characters and cause a sub-item to become selected. The
891 selection may also result in events fired on the parent object.
892 */
893 IA2_STATE_SUPPORTS_AUTOCOMPLETION = 0x8000,
894
895 /** Indicates this object is transient.
896
897 An object has this state when its parent object has the state ::IA2_STATE_MANAG ES_DESCENDANTS.
898 For example, a list item object may be managed by its parent list object and ma y only
899 exist as long as the object is actually rendered. Similarly a table cell's acc essible
900 object may exist only while the cell has focus. However, from the perspective of an
901 assistive technology a transient object behaves like a non-transient object. A s a
902 result it is likely that this state is not of use to an assistive technology, b ut it
903 is provided in case an assistive technology determines that knowledge of the tr ansient
904 nature of the object is useful and also for harmony with the Linux accessibilit y API.
905
906 Also, see ::IA2_STATE_MANAGES_DESCENDANTS for more information.
907 */
908 IA2_STATE_TRANSIENT = 0x10000,
909
910 /** Indicates the orientation of this object is vertical. */
911 IA2_STATE_VERTICAL = 0x20000
912
913 };
914 /*************************************************************************
915 *
916 * File Name (Accessible2.idl)
917 *
918 * IAccessible2 IDL Specification
919 *
920 * Copyright (c) Linux Foundation 2007, 2009
921 * Copyright (c) IBM Corp. 2006
922 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
923 *
924 * This library is free software; you can redistribute it and/or
925 * modify it under the terms of the GNU Lesser General Public
926 * License version 2.1, as published by the Free Software Foundation; either
927 * version 2.1 of the License, or (at your option) any later version.
928 *
929 * This library is distributed in the hope that it will be useful,
930 * but WITHOUT ANY WARRANTY; without even the implied warranty of
931 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
932 * Lesser General Public License for more details.
933 *
934 * You should have received a copy of the GNU Lesser General Public
935 * License along with this library; if not, write to the Free Software
936 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 U SA
937 *
938 ************************************************************************/
939
940 /** @mainpage
941
942 @section _interfaces Interfaces
943 IAccessible2\n
944 IAccessibleAction\n
945 IAccessibleApplication\n
946 IAccessibleComponent\n
947 IAccessibleHypertext\n
948 IAccessibleHyperlink\n
949 IAccessibleImage\n
950 IAccessibleRelation\n
951 IAccessibleTable [deprecated]\n
952 IAccessibleTable2\n
953 IAccessibleTableCell\n
954 IAccessibleText\n
955 IAccessibleEditableText\n
956 IAccessibleValue
957
958 @section _structs Structs
959 IA2Locale\n
960 IA2TableModelChange\n
961 IA2TextSegment
962
963 @section _enums Enums
964 ::IA2CoordinateType values define the requested coordinate type (screen or par ent window).\n
965 ::IA2EventID values identify events.\n
966 ::IA2Role values defines roles which are in addition to the existing MSAA role s.\n
967 ::IA2ScrollType values define where to place an object or substring on the scr een.\n
968 ::IA2States values define states which are in addition to the existing MSAA st ates.\n
969 ::IA2TableModelChangeType values describe the kinds of changes made to a table (insert, delete, update).\n
970 ::IA2TextBoundaryType values define the requested text unit (character, word, sentence, line, paragraph).\n
971 ::IA2TextSpecialOffsets values define special offsets for use in the text inte rfaces.
972
973 @section _constants Constants
974 @ref grpRelations
975
976 @section _misc Miscellaneous
977 @ref _licensePage "LGPL License"\n
978 @ref _generalInfo "General Information"\n
979
980 @page _licensePage LGPL License
981 IAccessible2 IDL Specification
982
983 Copyright (c) Linux Foundation 2007, 2008\n
984 Copyright (c) IBM Corp. 2006\n
985 Copyright (c) Sun Microsystems, Inc. 2000, 2006
986
987 This library is free software; you can redistribute it and/or
988 modify it under the terms of the GNU Lesser General Public
989 License version 2.1, as published by the Free Software Foundation; either
990 version 2.1 of the License, or (at your option) any later version.
991
992 This library is distributed in the hope that it will be useful,
993 but WITHOUT ANY WARRANTY; without even the implied warranty of
994 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
995 Lesser General Public License for more details.
996
997 You should have received a copy of the GNU Lesser General Public
998 License along with this library; if not, write to the Free Software
999 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
1000
1001 You may also refer to http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html
1002
1003 @page _generalInfo General Information
1004 The following information is applicable to two or more interfaces.
1005
1006 @ref _errors\n
1007 @ref _memory\n
1008 &nbsp;&nbsp;@ref _arrayConsideration\n
1009 @ref _indexes\n
1010 @ref _enums\n
1011 @ref _specialOffsets\n
1012 @ref _dicoveringInterfaces\n
1013 @ref _changingInterfaces\n
1014 @ref _applicationInfo\n
1015 @ref _childIDs\n
1016 @ref _variants\n
1017 @ref _iaaction-iahyperlink\n
1018 @ref _trademark
1019
1020 @section _errors Error Handling
1021 HRESULT values are defined by the Microsoft&reg; Win32&reg; API. For more inf ormation, refer to
1022 <a href="http://msdn2.microsoft.com/en-us/library/bb401631.aspx">Interpreting HRESULT Values</a>
1023 in MSDN&reg;.
1024
1025 Note that the S_FALSE return value is considered a non-error value and the
1026 SUCCEEDED macro will return TRUE. S_FALSE is used when there is no failure
1027 but there was nothing valid to return, e.g. in IAccessible2::attributes when
1028 there are no attributes. When S_FALSE is returned [out] pointer types should
1029 be NULL and [out] longs should generally be 0, but sometimes -1 is used such
1030 as IAccessible2::indexInParent, IAccessibleText::caretOffset, and
1031 IAccessibleHypertext::hyperlinkIndex.
1032
1033 Note that for BSTR [out] variables common COM practice is that the server does
1034 the SysAllocString and the client does the SysFreeString. Also note that when
1035 NULL is returned there is no need for the client to call SysFreeString. Pleas e
1036 refer to the documentation for each method for more details regarding error ha ndling.
1037
1038 @section _memory Memory Management
1039 The following memory management issues should be considered:
1040 @li Although [out] BSTR variables are declared by the client, their space is
1041 allocated by the server. They need to be freed with SysFreeString by the
1042 client at end of life; the same is true when BSTRs are used in structs or
1043 arrays which are passed to the server.
1044 @li If there is no valid [out] BSTR to return, the server should return S_FALS E and
1045 assign NULL to the output, e.g. *theOutBSTR = NULL;.
1046 @li COM interfaces need to be referenced with AddRef when used and dereference d
1047 with Release at end of life.
1048 @li Single [out] longs, HWNDs, booleans, and structs are declared by the calle r
1049 and passed by reference. The marshaller does all the memory management.
1050
1051 The following articles may be helpful for understanding memory management issu es:
1052 @li An article by Don Box in a
1053 <a href="http://www.microsoft.com/msj/1196/activex1196.aspx">Q & A section</a >
1054 of the November 1996 edition of the Microsoft Systems Journal.
1055 @li A posting to a CodeGuru forum,
1056 <a href="http://www.codeguru.com/forum/showthread.php?t=364511">Windows SDK
1057 String: What are the rules for BSTR allocation and deallocation?</a>
1058
1059 @subsection _arrayConsideration Special Consideration when using Arrays
1060 There are several methods which return arrays. It is considered a best practi ce
1061 for the client to allocate and free the arrays. This can be done for
1062 IAccessible2::relations and IAccessibleRelation::targets. However, due to the
1063 coding of the IDL for the remaining methods which return arrays, the server mu st
1064 allocate the array and the client must free the array when no longer needed.
1065 These methods are IAccessible2::extendedStates, IAccessible2::localizedExtende dStates,
1066 IAccessibleAction::keyBinding, IAccessibleTable::selectedChildren,
1067 IAccessibleTable::selectedColumns, and IAccessibleTable::selectedRows. For th ose
1068 methods, the server must allocate both the top level array and any storage
1069 associated with it, e.g. for BSTRs. The client must use CoTaskMemFree to free
1070 the array and any BSTRs must be freed with SysFreeString.
1071
1072 Also, the IDL for those methods includes an extraneous [in] parameter for the
1073 caller to specify the max size of the array. This parameter will be ignored b y
1074 the COM server.
1075
1076 @section _indexes Zero and One Based Indexes
1077 Unless otherwise specified all offsets and indexes are 0 based.
1078
1079 @section _enums Enums
1080 Note that enums start at 0.
1081
1082 @section _specialOffsets Special Offsets for use in the IAccessibleText and IAc cessibleEditableText Methods
1083 IAccessibleText and IAccessibleEditableText can use one or more of the followi ng
1084 special offset values. They are defined in the ::IA2TextSpecialOffsets enum.
1085 @li Using ::IA2_TEXT_OFFSET_LENGTH (-1) as an offset in any of the IAccessible Text or
1086 IAccessibleEditableText methods is the same as specifying the length of the s tring.
1087 @li Using ::IA2_TEXT_OFFSET_CARET (-2) as an offset for IAccessibleText::textB eforeOffset,
1088 IAccessibleText::textAtOffset, and IAccessibleText::textAfterOffset indicates that the
1089 text related to the physical location of the caret should be used. This is n eeded for
1090 applications that consider the character offset of the end of one line (as re ached by
1091 pressing the End key) the same as the offset of the first character on the ne xt line.
1092 Since the same offset is associated with two different lines a special means is needed
1093 to fetch text from the line where the caret is physically located.
1094
1095 @section _dicoveringInterfaces Discovery of Interfaces
1096 In general AT (Assistive Technology) should try IAccessible2 interfaces, follo wed by using
1097 the MSAA (Microsoft&reg; Active Accessibility&reg;) interfaces. (In cases whe re the an application
1098 is known to have custom interfaces which provide information not supplied by I Accessible2
1099 or MSAA, then those custom interfaces can be used.) The AT can then, by defau lt, support
1100 unknown IAccessible2/MSAA applications, without the application developers hav ing to request
1101 AT vendors for support on an individual application by application basis.
1102
1103 When you have a reference to an IAccessible and require a reference to an IAcc essible2 use
1104 QueryService as follows:
1105 @code
1106 // pAcc is a reference to the accessible object's IAccessible interface.
1107 IServiceProvider *pService = NULL;
1108 hr = pAcc->QueryInterface(IID_IServiceProvider, (void **)&pService);
1109 if(SUCCEEDED(hr)) {
1110 IAccessible2 *pIA2 = NULL;
1111 hr = pService->QueryService(IID_IAccessible, IID_IAccessible2, (void**)&pIA2 );
1112 if (SUCCEEDED(hr) && pIA2) {
1113 // The control supports IAccessible2.
1114 // pIA2 is the reference to the accessible object's IAccessible2 interface .
1115 }
1116 }
1117 @endcode
1118
1119 @section _changingInterfaces Changing between Accessible Interfaces
1120 Note that developers must always implement MSAA's IAccessible and, if needed, some
1121 of the interfaces in the set of IAccessible2 interfaces. Although the IAccess ible2
1122 IDL is currently coded such that IAccessible2 is a subclass of MSAA's IAccessi ble,
1123 none of MSAA's IAccessible methods are overridden or extended. In order to al low
1124 future removal of the inheritance, Assistive Technologies (ATs) should not rel y on
1125 that inheritance.
1126
1127 QueryService must be used to switch from a reference to an MSAA IAccessible in terface
1128 to another interface. This has been
1129 <a href="http://www.accessinteropalliance.org/docs/Introducing_IAccessibleEx.d oc">
1130 documented by Microsoft</a> and the pertinent facts have been extracted below:
1131
1132 @par
1133 Why use QueryService instead of just using QueryInterface to get IAccessibleE x
1134 directly? The reason is that since MSAA 2.0, clients don't talk to a server's
1135 IAccessible interface directly; instead they talk to an intermediate MSAA-pro vided
1136 wrapper that calls through to the original IAccessible. This wrapper provides services
1137 such as implementing IDispatch, supplying information from MSAA 2.0's Dynamic Annotation
1138 service, and scaling locations when running on Windows Vista with DPI scaling enabled.
1139 QueryService is the supported way to expose additional interfaces from an exi sting
1140 IAccessible and was originally used by MSHTML to expose IHTMLElement objects corresponding
1141 to IAccessibles. QueryService is often more convenient for servers to impleme nt than
1142 QueryInterface because it does not have the same requirements for preserving object
1143 identity or symmetry/transitivity as QueryInterface, so QueryService allows s ervers to
1144 easily implement the interface on the same object or a separate object. The l atter is
1145 often hard to do with QueryInterface unless the original object supports aggr egation.
1146
1147 Two related references in MSDN&reg; are:
1148 @li <a href="http://msdn.microsoft.com/en-us/library/ms696078(VS.85).aspx">
1149 "Using QueryService to expose a native object model interface for an IAccessib le object"</a>
1150 @li <a href="http://msdn.microsoft.com/en-us/library/ms528415.aspx#acc_obj">
1151 "Accessing the Internet Explorer Object Associated with an Accessible Object"< /a>
1152
1153 Based on this information from Microsoft, QueryService must be used to switch back and forth
1154 between a reference to an MSAA IAccessible interface and any of the IAccessibl e2 interfaces.
1155
1156 Regarding switching between any of the IAccessible2 interfaces, applications i mplementing
1157 IAccessible2 should implement the IAccessible2 interfaces on a single object s ince ATs
1158 will be using QueryInterface to switch between the IAccessilbe2 interfaces. I mplementing
1159 the IAccessible2 interfaces on separate objects would require the use of Query Service.
1160 There is one exception, IAccessibleApplication can be implemented on a separat e object so
1161 its common code doesn't have to be included in each accessible object. ATs sh ould use
1162 QueryService to access IAccessibleApplication.
1163
1164 @section _applicationInfo Access to Information about the Application
1165 Servers implementing IAccessible2 should provide access to the IAccessibleAppl ication
1166 interface via QueryService from any object so that ATs can easily determine sp ecific
1167 information about the application such as its name or version.
1168
1169 @section _childIDs Child IDs
1170 The IAccessible2 interfaces do not support child IDs, i.e. simple child elemen ts.
1171 Full accessible objects must be created for each object that supports IAccessi ble2.
1172 Therefore MSAA's get_accChild should never return a child ID (other than CHILD ID_SELF)
1173 for an object that implements any of the IAccessible2 interfaces.
1174
1175 Microsoft's UI Automation specification has the same limitation and this was r esolved
1176 in the UI Automation Express specification by adding IAccessibleEx::GetObjectF orChild
1177 and IAccessibleEx::GetIAccessiblePair. These methods allow mapping back and f orth
1178 between an IAccessibleEx and an {IAccessible, Child ID} pair. A future versio n of
1179 IAccessible2 may include similar methods to map back and forth between an IAcc essible2
1180 and an {IAccessible, Child ID} pair.
1181
1182 @section _variants VARIANTs
1183 Some methods return a VARIANT. Implementers need to make sure that the return type is
1184 specified, i.e. VT_I4, VT_IDISPATCH, etc. The methods that return VARIANTs ar e
1185 IAccessibleHyperlink::anchor, IAccessibleHyperlink::anchorTarget, IAccessibleV alue::currentValue,
1186 IAccessibleValue::maximumValue, IAccessibleValue::minimumValue.
1187
1188 @section _iaaction-iahyperlink IAccessibleHyperlink as subclass of IAccessibleA ction
1189 In this version of the IDL, IAccessibleHyperlink is a subclass of IAccessibleA ction.
1190 However, there is no practical need for that inheritance and in some cases, su ch as
1191 an image map of smart tags, it doesn't make sense because such an image map do esn't
1192 have actionable objects; it's the secondary smart tags that are actionable. A s a
1193 result, implementations should not rely on the inheritance as it may be remove d in
1194 a later version of the IDL.
1195
1196 @section _trademark Trademark Attribution
1197 The names of actual companies and products mentioned herein may be the tradema rks of
1198 their respective owners. In particular, Active Accessibility, Microsoft, MSDN , and Win32
1199 are trademarks of the Microsoft group of companies in the U.S.A. and/or other countries.
1200
1201 **/
1202
1203 import "objidl.idl";
1204 import "oaidl.idl";
1205 import "oleacc.idl";
1206
1207
1208
1209
1210 /** A structure defining the locale of an accessible object.
1211
1212 IAccessible2::locale returns this struct.
1213 */
1214 typedef struct IA2Locale {
1215 BSTR language; ///< ISO 639-1 Alpha-2 two character language code
1216 BSTR country; ///< ISO 3166-1 Alpha-2 two character country code
1217 BSTR variant; ///< Application specific variant of the locale
1218 } IA2Locale;
1219
1220 /** This interface must always be provided for objects that support some
1221 portion of the collection of the %IAccessible2 interfaces.
1222
1223 Please refer to @ref _changingInterfaces "Changing between Accessible Interface s"
1224 for special considerations related to use of the MSAA IAccessible interface and
1225 the set of %IAccessible2 interfaces.
1226
1227 */
1228 [object, uuid(E89F726E-C4F4-4c19-BB19-B647D7FA8478)]
1229 interface IAccessible2 : IAccessible
1230 {
1231
1232 /** @brief Returns the number of accessible relations for this object.
1233 @param [out] nRelations
1234 @retval S_OK
1235 */
1236 [propget] HRESULT nRelations
1237 (
1238 [out, retval] long *nRelations
1239 );
1240
1241 /** @brief Returns one accessible relation for this object.
1242 @param [in] relationIndex
1243 0 based
1244 @param [out] relation
1245 @retval S_OK
1246 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
1247 */
1248 [propget] HRESULT relation
1249 (
1250 [in] long relationIndex,
1251 [out, retval] IAccessibleRelation **relation
1252 );
1253
1254 /** @brief Returns multiple accessible relations for this object.
1255 @param [in] maxRelations
1256 maximum size of the array allocated by the client
1257 @param [out] relations
1258 The array of accessible relation objects. Note that this array is to be
1259 allocated by the client and freed when no longer needed. Refer to @ref
1260 _arrayConsideration "Special Consideration when using Arrays" for more d etails.
1261 @param [out] nRelations
1262 actual number of relations in the returned array (not more than maxRelations )
1263 @retval S_OK
1264 @retval S_FALSE if there are no relations, nRelations is set to 0
1265 */
1266 [propget] HRESULT relations
1267 (
1268 [in] long maxRelations,
1269 [out, size_is(maxRelations), length_is(*nRelations)]
1270 IAccessibleRelation **relations,
1271 [out, retval] long *nRelations
1272 );
1273
1274 /** @brief Returns the role of an %IAccessible2 object.
1275 @param [out] role
1276 The role of an %IAccessible2 object.
1277 @retval S_OK
1278 @note
1279 @li For convenience MSAA roles are also passed through this method so the
1280 AT doesn't have to also fetch roles through MSAA's get_accRole.
1281 @li %IAccessible2 roles should not be passed through MSAA's get_accRole.
1282 @li For compatibility with non IAccessible2 enabled ATs, IAccessible2
1283 applications should also add support to get_accRole to return the closest
1284 MSAA role or ROLE_SYSTEM_CLIENT (the MSAA defined default role) if there
1285 is not a good match.
1286 @li This method is missing a [propget] prefix in the IDL. The result is the
1287 method is named role in generated C++ code instead of get_role.
1288 */
1289 HRESULT role
1290 (
1291 [out, retval] long *role
1292 );
1293
1294 /** @brief Makes an object visible on the screen.
1295 @param [in] scrollType
1296 Defines where the object should be placed on the screen.
1297 @retval S_OK
1298 @retval E_INVALIDARG if bad [in] passed
1299 */
1300 HRESULT scrollTo
1301 (
1302 [in] enum IA2ScrollType scrollType
1303 );
1304
1305 /** @brief Moves the top left of an object to a specified location.
1306
1307 @param [in] coordinateType
1308 Specifies whether the coordinates are relative to the screen or the parent o bject.
1309 @param [in] x
1310 Defines the x coordinate.
1311 @param [in] y
1312 Defines the y coordinate.
1313 @retval S_OK
1314 @retval E_INVALIDARG if bad [in] passed
1315 */
1316 HRESULT scrollToPoint
1317 (
1318 [in] enum IA2CoordinateType coordinateType,
1319 [in] long x,
1320 [in] long y
1321 );
1322
1323 /** @brief Returns grouping information.
1324
1325 Used for tree items, list items, tab panel labels, radio buttons, etc.
1326 Also used for collections of non-text objects.
1327
1328 @param [out] groupLevel
1329 1 based, 0 indicates that this value is not applicable
1330 @param [out] similarItemsInGroup
1331 1 based, 0 indicates that this value is not applicable
1332 @param [out] positionInGroup
1333 1 based, 0 indicates that this value is not applicable. This is an index
1334 into the objects in the current group, not an index into all the objects
1335 at the same group level.
1336 @retval S_OK if at least one value is valid
1337 @retval S_FALSE if no values are valid
1338 @note This method is meant to describe the nature of an object's containment
1339 structure. This is normally not implemented on a combo box to describe the nature
1340 of its contents. Normally an AT will get that information from its child li st
1341 object. However, in some cases when combo boxes are not able to be stru ctured
1342 such that the list is a child of the combo box, this method is implement ed
1343 on the combo box itself. ATs can use this interface if a child list is n ot found.
1344 */
1345 [propget] HRESULT groupPosition
1346 (
1347 [out] long *groupLevel,
1348 [out] long *similarItemsInGroup,
1349 [out, retval] long *positionInGroup
1350 );
1351
1352 /** @brief Returns the bit strip containing any IAccessible2 states.
1353
1354 The IAccessible2 states are in addition to the MSAA states and are defined in
1355 the IA2States enum.
1356
1357 @param [out] states
1358 @retval S_OK
1359 */
1360 [propget] HRESULT states
1361 (
1362 [out, retval] AccessibleStates *states
1363 );
1364
1365 /** @brief Returns the extended role.
1366
1367 An extended role is a role which is dynamically generated by the application.
1368 It is not predefined by the %IAccessible2 specification.
1369
1370 @param [out] extendedRole
1371 @retval S_OK
1372 @retval S_FALSE if there is nothing to return, [out] value is NULL
1373 */
1374 [propget] HRESULT extendedRole
1375 (
1376 [out, retval] BSTR *extendedRole
1377 );
1378
1379 /** @brief Returns the localized extended role.
1380 @param [out] localizedExtendedRole
1381 @retval S_OK
1382 @retval S_FALSE if there is nothing to return, [out] value is NULL
1383 */
1384 [propget] HRESULT localizedExtendedRole
1385 (
1386 [out, retval] BSTR *localizedExtendedRole
1387 );
1388
1389 /** @brief Returns the number of extended states.
1390 @param [out] nExtendedStates
1391 @retval S_OK
1392 */
1393 [propget] HRESULT nExtendedStates
1394 (
1395 [out, retval] long *nExtendedStates
1396 );
1397
1398 /** @brief Returns the extended states (array of strings).
1399
1400 An extended state is a state which is dynamically generated by the applicatio n.
1401 It is not predefined by the %IAccessible2 specification.
1402
1403 @param [in] maxExtendedStates
1404 This parameter is ignored. Refer to @ref _arrayConsideration
1405 "Special Consideration when using Arrays" for more details.
1406 @param [out] extendedStates
1407 This array is allocated by the server. Free it with CoTaskMemFree.
1408 @param [out] nExtendedStates
1409 The number of extended states returned; the size of the returned array.
1410 @retval S_OK
1411 @retval S_FALSE if there are no states, [out] values are NULL and 0 respectiv ely
1412 */
1413 [propget] HRESULT extendedStates
1414 (
1415 [in] long maxExtendedStates,
1416 [out, size_is(,maxExtendedStates), length_is(,*nExtendedStates)] BSTR **ext endedStates,
1417 [out, retval] long *nExtendedStates
1418 );
1419
1420 /** @brief Returns the localized extended states (array of strings).
1421 @param [in] maxLocalizedExtendedStates
1422 This parameter is ignored. Refer to @ref _arrayConsideration
1423 "Special Consideration when using Arrays" for more details.
1424 @param [out] localizedExtendedStates
1425 This array is allocated by the server. Free it with CoTaskMemFree.
1426 @param [out] nLocalizedExtendedStates
1427 The number of localized extended states returned; the size of the returned a rray.
1428 @retval S_OK
1429 @retval S_FALSE if there are no states, [out] values are NULL and 0 respectiv ely
1430 */
1431 [propget] HRESULT localizedExtendedStates
1432 (
1433 [in] long maxLocalizedExtendedStates,
1434 [out, size_is(,maxLocalizedExtendedStates), length_is(,*nLocalizedExtendedS tates)] BSTR **localizedExtendedStates,
1435 [out, retval] long *nLocalizedExtendedStates
1436 );
1437
1438 /** @brief Returns the unique ID.
1439
1440 The uniqueID is an identifier for this object, is unique within the
1441 current window, and remains the same for the lifetime of the accessible
1442 object.
1443
1444 The uniqueID is not related to:
1445 - the MSAA objectID which is used by the server to disambiguate between
1446 IAccessibles per HWND or
1447 - the MSAA childID which is used to disambiguate between children being
1448 managed by an IAccessible.
1449
1450 This value is provided so the AT can have access to a unique runtime persiste nt
1451 identifier even when not handling an event for the object.
1452
1453 An example of when this value is useful is if the AT wants to build a cache.
1454 The AT could cache the uniqueIDs in addition to other data being cached.
1455 When an event is fired the AT could map the uniqueID to its internal model.
1456 Thus, if there's a REORDER/SHOW/HIDE event the AT knows which part of the
1457 internal structure has been invalidated and can refetch just that part.
1458
1459 This value can also be used by an AT to determine when the current control
1460 has changed. If the role is the same for two controls that are adjacent in
1461 the tab order, this can be used to detect the new control.
1462
1463 Another use of this value by an AT is to identify when a grouping object has
1464 changed, e.g. when moving from a radio button in one group to a radio button in a
1465 different group.
1466
1467 One means of implementing this would be to create a factory with a 32 bit num ber
1468 generator and a reuse pool. The number generator would emit numbers starting
1469 at 1. Each time an object's life cycle ended, its number would be saved into a
1470 resuse pool. The number generator would be used whenever the reuse pool was empty.
1471
1472 @param [out] uniqueID
1473 @retval S_OK
1474 */
1475 [propget] HRESULT uniqueID
1476 (
1477 [out, retval] long *uniqueID
1478 );
1479
1480 /** @brief Returns the window handle for the parent window which contains this object.
1481
1482 This is the same window handle which will be passed for any events that occur on the
1483 object, but is cached in the accessible object for use when it would be helpf ul to
1484 access the window handle in cases where an event isn't fired on this object.
1485
1486 A use case is when a screen reader is grabbing an entire web page on a page l oad.
1487 Without the availability of windowHandle, the AT would have to get the window handle
1488 by using WindowFromAccessibleObject on each IAccessible, which is slow becaus e it's
1489 implemented by oleacc.dll as a loop which crawls up the ancestor chain and lo oks for
1490 a ROLE_WINDOW object, mapping that back to a window handle.
1491
1492 @param [out] windowHandle
1493 @retval S_OK
1494 */
1495 [propget] HRESULT windowHandle
1496 (
1497 [out, retval] HWND *windowHandle
1498 );
1499
1500 /** @brief Returns the index of this object in its parent object.
1501 @param [out] indexInParent
1502 0 based; -1 indicates there is no parent; the upper bound is the value
1503 returned by the parent's IAccessible::get_accChildCount.
1504 @retval S_OK
1505 @retval S_FALSE if no parent, [out] value is -1
1506 */
1507 [propget] HRESULT indexInParent
1508 (
1509 [out, retval] long *indexInParent
1510 );
1511
1512 /** @brief Returns the IA2Locale of the accessible object.
1513 @param [out] locale
1514 @retval S_OK
1515 */
1516 [propget] HRESULT locale
1517 (
1518 [out, retval] IA2Locale *locale
1519 );
1520
1521 /** @brief Returns the attributes specific to this %IAccessible2 object, such as a cell's formula.
1522 @param [out] attributes
1523 @retval S_OK
1524 @retval S_FALSE returned if there is nothing to return, [out] value is NULL
1525 */
1526 [propget] HRESULT attributes
1527 (
1528 [out, retval] BSTR *attributes
1529 );
1530
1531 }
1532
1533 /*************************************************************************
1534 *
1535 * File Name (AccessibleComponent.idl)
1536 *
1537 * IAccessible2 IDL Specification
1538 *
1539 * Copyright (c) Linux Foundation 2007, 2008
1540 * Copyright (c) IBM Corp. 2006
1541 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
1542 *
1543 * This library is free software; you can redistribute it and/or
1544 * modify it under the terms of the GNU Lesser General Public
1545 * License version 2.1, as published by the Free Software Foundation; either
1546 * version 2.1 of the License, or (at your option) any later version.
1547 *
1548 * This library is distributed in the hope that it will be useful,
1549 * but WITHOUT ANY WARRANTY; without even the implied warranty of
1550 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
1551 * Lesser General Public License for more details.
1552 *
1553 * You should have received a copy of the GNU Lesser General Public
1554 * License along with this library; if not, write to the Free Software
1555 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02110-1301 USA
1556 *
1557 ************************************************************************/
1558
1559 import "objidl.idl";
1560 import "oaidl.idl";
1561 import "oleacc.idl";
1562
1563 /** A value specifying a color in ARGB format, where each 8 bit color component
1564 specifies alpha, red, green, and blue respectively. The alpha value is optional .
1565 */
1566 typedef long IA2Color;
1567
1568 /** @brief This interface is implemented by any object that can be rendered
1569 on the screen.
1570
1571 This interface provides the standard mechanism for an assistive technology
1572 to retrieve information concerning the graphical representation of an object.
1573 Coordinates used by the functions of this interface are specified in
1574 different coordinate systems. Their scale is the same and is equal to
1575 that of the screen coordinate system. In other words all coordinates
1576 are measured in pixels. They differ in their respective origin:
1577 <ul>
1578 <li>The screen coordinate system has its origin in the upper left
1579 corner of the current screen.</li>
1580 <li>The origin of the parent coordinate system is the upper left corner
1581 of the parent's bounding box. With no parent the screen coordinate
1582 system is used instead.</li>
1583 </ul>
1584 */
1585 [object, uuid(1546D4B0-4C98-4bda-89AE-9A64748BDDE4)]
1586 interface IAccessibleComponent : IUnknown
1587 {
1588
1589 /** @brief Returns the location of the upper left corner of the object's
1590 bounding box relative to the immediate parent object.
1591
1592 The coordinates of the bounding box are given relative to the parent's
1593 coordinate system. The coordinates of the returned position are relative
1594 to this object's parent or relative to the screen on which this object
1595 is rendered if it has no parent. If the object is not on any screen
1596 the returned position is (0,0).
1597
1598 @param [out] x
1599 @param [out] y
1600 @retval S_OK
1601 */
1602 [propget] HRESULT locationInParent
1603 (
1604 [out] long *x,
1605 [out, retval] long *y
1606 );
1607
1608 /** @brief Returns the foreground color of this object.
1609 @param [out] foreground
1610 The returned color is the foreground color of this object or, if
1611 that is not supported, the default foreground color.
1612 @retval S_OK
1613 */
1614 [propget] HRESULT foreground
1615 (
1616 [out, retval] IA2Color *foreground
1617 );
1618
1619 /** @brief Returns the background color of this object.
1620 @param [out] background
1621 The returned color is the background color of this object or, if
1622 that is not supported, the default background color.
1623 @retval S_OK
1624 */
1625 [propget] HRESULT background
1626 (
1627 [out, retval] IA2Color *background
1628 );
1629 }
1630 /*************************************************************************
1631 *
1632 * File Name (AccessibleValue)
1633 *
1634 * IAccessible2 IDL Specification
1635 *
1636 * Copyright (c) Linux Foundation 2007, 2008
1637 * Copyright (c) IBM Corp. 2006
1638 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
1639 *
1640 * This library is free software; you can redistribute it and/or
1641 * modify it under the terms of the GNU Lesser General Public
1642 * License version 2.1, as published by the Free Software Foundation; either
1643 * version 2.1 of the License, or (at your option) any later version.
1644 *
1645 * This library is distributed in the hope that it will be useful,
1646 * but WITHOUT ANY WARRANTY; without even the implied warranty of
1647 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
1648 * Lesser General Public License for more details.
1649 *
1650 * You should have received a copy of the GNU Lesser General Public
1651 * License along with this library; if not, write to the Free Software
1652 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02110-1301 USA
1653 *
1654 ************************************************************************/
1655
1656 import "objidl.idl";
1657 import "oaidl.idl";
1658 import "oleacc.idl";
1659
1660 /** @brief This interface gives access to a single numerical value.
1661
1662 The %IAccessibleValue interface represents a single numerical value and should
1663 be implemented by any class that supports numerical value like progress bars
1664 and spin boxes. This interface lets you access the value and its upper and
1665 lower bounds.
1666 */
1667 [object, uuid(35855B5B-C566-4fd0-A7B1-E65465600394)]
1668 interface IAccessibleValue : IUnknown
1669 {
1670
1671 /** @brief Returns the value of this object as a number.
1672
1673 The exact return type is implementation dependent. Typical types are long an d
1674 double.
1675 @param [out] currentValue
1676 Returns the current value represented by this object. See the section about
1677 @ref _variants "VARIANTs" for additional information.
1678 @retval S_OK
1679 @retval S_FALSE if there is nothing to return, [out] value is NULL
1680 */
1681 [propget] HRESULT currentValue
1682 (
1683 [out, retval] VARIANT *currentValue
1684 );
1685
1686 /** @brief Sets the value of this object to the given number.
1687
1688 The argument is clipped to the valid interval whose upper and lower
1689 bounds are returned by the methods IAccessibleValue::maximumValue and
1690 IAccessibleValue::minimumValue, i.e. if it is lower than the minimum
1691 value the new value will be the minimum and if it is greater than the
1692 maximum then the new value will be the maximum.
1693
1694 @param [out] value
1695 The new value represented by this object. The set of admissible types for
1696 this argument is implementation dependent.
1697 @retval S_OK
1698 */
1699 HRESULT setCurrentValue
1700 (
1701 [in] VARIANT value
1702 );
1703
1704 /** @brief Returns the maximal value that can be represented by this object.
1705
1706 The type of the returned value is implementation dependent. It does not have
1707 to be the same type as that returned by method IAccessibleValue::currentValu e.
1708
1709 @param [out] maximumValue
1710 Returns the maximal value in an implementation dependent type. If this objec t
1711 has no upper bound then an empty object is returned. See the section about
1712 @ref _variants "VARIANTs" for additional information.
1713 @retval S_OK
1714 */
1715 [propget] HRESULT maximumValue
1716 (
1717 [out, retval] VARIANT *maximumValue
1718 );
1719
1720 /** @brief Returns the minimal value that can be represented by this object.
1721
1722 The type of the returned value is implementation dependent. It does not have
1723 to be the same type as that returned by method IAccessibleValue::currentValu e.
1724
1725 @param [out] minimumValue
1726 Returns the minimal value in an implementation dependent type. If this objec t
1727 has no lower bound then an empty object is returned. See the section about
1728 @ref _variants "VARIANTs" for additional information.
1729 @retval S_OK
1730 */
1731 [propget] HRESULT minimumValue
1732 (
1733 [out, retval] VARIANT *minimumValue
1734 );
1735
1736 };
1737 /*************************************************************************
1738 *
1739 * File Name (AccessibleText.idl)
1740 *
1741 * IAccessible2 IDL Specification
1742 *
1743 * Copyright (c) Linux Foundation 2007, 2008
1744 * Copyright (c) IBM Corp. 2006
1745 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
1746 *
1747 * This library is free software; you can redistribute it and/or
1748 * modify it under the terms of the GNU Lesser General Public
1749 * License version 2.1, as published by the Free Software Foundation; either
1750 * version 2.1 of the License, or (at your option) any later version.
1751 *
1752 * This library is distributed in the hope that it will be useful,
1753 * but WITHOUT ANY WARRANTY; without even the implied warranty of
1754 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
1755 * Lesser General Public License for more details.
1756 *
1757 * You should have received a copy of the GNU Lesser General Public
1758 * License along with this library; if not, write to the Free Software
1759 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 U SA
1760 *
1761 ************************************************************************/
1762
1763 import "objidl.idl";
1764 import "oaidl.idl";
1765 import "oleacc.idl";
1766
1767
1768 /** A structure containing a substring and the start and end offsets in the encl osing string.
1769
1770 IAccessibleText::newText and IAccessibleText::oldText return this struct.
1771 */
1772 typedef struct IA2TextSegment {
1773 BSTR text; ///< A copy of a segment of text taken from an enclosing paragra ph.
1774 long start; ///< Index of the first character of the segment in the enclosin g text.
1775 long end; ///< Index of the character following the last character of the segment in the enclosing text.
1776 } IA2TextSegment;
1777
1778 /** This enum defines values which specify a text boundary type.
1779
1780 IA2_TEXT_BOUNDARY_SENTENCE is optional. When a method doesn't implement this
1781 method it must return S_FALSE. Typically this feature would not be implemented
1782 by an application. However, if the application developer was not satisfied wit h
1783 how screen readers have handled the reading of sentences this boundary type
1784 could be implemented and screen readers could use the application's version of a
1785 sentence rather than the screen reader's.
1786
1787 The rest of the boundary types must be supported.
1788
1789 This enum is used in IAccessibleText::textBeforeOffset, IAccessibleText::textAt Offset,
1790 and IAccessibleText::textAfterOffset.
1791 */
1792
1793 enum IA2TextBoundaryType {
1794 IA2_TEXT_BOUNDARY_CHAR, /**< Typically, a single character is re turned. In some cases more than
1795 one character i s returned, for example, when a document contains field
1796 data such as a field containing a date, time, or footnote reference.
1797 In this case th e caret can move over several characters in one movement
1798 of the caret. Note that after the caret moves, the caret offset changes
1799 by the number o f characters in the field, e.g. by 8 characters in the
1800 following date: 03/26/07. */
1801 IA2_TEXT_BOUNDARY_WORD, /**< The range provided matches the rang e observed when the application
1802 processes the C trl + left arrow and Ctrl + right arrow key sequences.
1803 Typically this is from the start of one word to the start of the next, but
1804 various applica tions are inconsistent in the handling of the end of a line. */
1805 IA2_TEXT_BOUNDARY_SENTENCE, ///< Range is from start of one sentence to the start of another sentence.
1806 IA2_TEXT_BOUNDARY_PARAGRAPH, ///< Range is from start of one paragraph to the start of another paragraph.
1807 IA2_TEXT_BOUNDARY_LINE, /**< Range is from start of one line to the start of another line. This
1808 often means that an end-of-line character will appear at the end of the
1809 range. However in the case of some applications an end-of-line character
1810 indicates the e nd of a paragraph and the lines composing the paragraph,
1811 other than the last line, do not contain an end of line character. */
1812 IA2_TEXT_BOUNDARY_ALL ///< Using this value will cause all tex t to be returned.
1813 };
1814
1815 /** @brief This interface gives read-only access to text.
1816
1817 The %IAccessibleText interface should be implemented by all components
1818 that present textual information on the display like buttons,
1819 text entry fields, or text portions of the document window. The interface
1820 provides access to the text's content, attributes, and spatial location.
1821 However, text can not be modified with this interface. That is the task
1822 of the IAccessibleEditableText interface.
1823
1824 The text length, i.e. the number of characters in the text, is
1825 returned by IAccessibleText::nCharacters. All methods that operate
1826 on particular characters (e.g. IAccessibleText::textAtOffset) use character
1827 indices from 0 to length-1. All methods that operate on character positions
1828 (e.g. IAccessibleText::text) use indices from 0 to length.
1829
1830 Please note that accessible text does not necessarily support selection.
1831 In this case it should behave as if there where no selection. An empty
1832 selection is used for example to express the current cursor position.
1833
1834 Refer to @ref _specialOffsets
1835 "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Me thods"
1836 for information about special offsets that can be used in %IAccessibleText met hods.
1837
1838 E_FAIL is returned in the following cases
1839 @li endOffset < startOffset
1840 @li endoffset > length
1841 */
1842 [object, uuid(24FD2FFB-3AAD-4a08-8335-A3AD89C0FB4B)]
1843 interface IAccessibleText : IUnknown
1844 {
1845
1846 /** @brief Adds a text selection
1847 @param [in] startOffset
1848 Starting offset ( 0 based).
1849 @param [in] endOffset
1850 Offset of first character after new selection (0 based).
1851 @retval S_OK
1852 @retval E_INVALIDARG if bad [in] passed
1853 */
1854 HRESULT addSelection
1855 (
1856 [in] long startOffset,
1857 [in] long endOffset
1858 );
1859
1860 /** @brief Returns text attributes.
1861 @param [in] offset
1862 Text offset (0 based)
1863 @param [out] startOffset
1864 The starting offset of the character range over which all text attributes ma tch
1865 those of offset. (0 based)
1866 @param [out] endOffset
1867 The offset of the first character past the character range over which all te xt
1868 attributes match those of offset. (0 based)
1869 @param [out] textAttributes
1870 A string of attributes describing the text. The attributes are described in the
1871 <a href="http://www.linuxfoundation.org/en/Accessibility/IAccessible2/TextAt tributes">
1872 text attributes specification</a> on the %IAccessible2 web site.
1873 @retval S_OK
1874 @retval S_FALSE if there is nothing to return, [out] values are 0s and NULL r espectively
1875 @retval E_INVALIDARG if bad [in] passed, [out] values are 0s and NULL respect ively
1876
1877 */
1878 [propget] HRESULT attributes
1879 (
1880 [in] long offset,
1881 [out] long *startOffset,
1882 [out] long *endOffset,
1883 [out, retval] BSTR *textAttributes
1884 );
1885
1886 /** @brief Returns the position of the caret.
1887
1888 Returns the 0-based offset of the caret within the text. If the text is
1889 implemented as a tree of text objects with embed characters in higher levels
1890 representing substrings of child text objects and the caret is in one of the
1891 child text objects, then the offset in the higher level text object would be
1892 at the embed character representing child text object that contains the caret .
1893
1894 For example, if the string "one two three" is implemented as a two text objec ts,
1895 with a top level text object containing an embed character "one ? three" and a
1896 child text object containing "two" and if the caret is in the descendant obje ct
1897 just before the 'o' in "two", then:
1898 <ul>
1899 <li>the caretOffset for the "one ? three" object would be 4, matching the emb ed character</li>
1900 <li>the caretOffset for "two" would be 2, matching the "o"</li>
1901 </ul>
1902 The caret position/offset is that of the character logically following it, e. g.
1903 to the right of it in a left to right language.
1904 @param [out] offset
1905 The returned offset is relative to the text represented by this object.
1906 @retval S_OK
1907 @retval S_FALSE if the caret is not currently active on this object, i.e. the
1908 caret is located on some other object. The returned offset value will be -1 .
1909 @note S_FALSE (and an offset of -1) will not be returned if the caret is some where
1910 in the text object or one of its descendants.
1911 */
1912 [propget] HRESULT caretOffset
1913 (
1914 [out, retval] long *offset
1915 );
1916
1917
1918 /** @brief Returns the bounding box of the specified position.
1919
1920 The virtual character after the last character of the represented
1921 text, i.e. the one at position length is a special case. It represents the
1922 current input position and will therefore typically be queried by AT more
1923 often than other positions. Because it does not represent an existing chara cter
1924 its bounding box is defined in relation to preceding characters. It should be
1925 roughly equivalent to the bounding box of some character when inserted at th e
1926 end of the text. Its height typically being the maximal height of all the
1927 characters in the text or the height of the preceding character, its width b eing
1928 at least one pixel so that the bounding box is not degenerate.
1929
1930 Note that the index 'length' is not always valid. Whether it is or not is
1931 implementation dependent. It typically is when text is editable or otherwis e
1932 when on the screen the caret can be placed behind the text. You can be sure
1933 that the index is valid after you have received a ::IA2_EVENT_TEXT_CARET_MOV ED
1934 event for this index.
1935 @param [in] offset
1936 Index of the character for which to return its bounding box. The valid range
1937 is 0..length.
1938 @param [in] coordType
1939 Specifies if the coordinates are relative to the screen or to the parent win dow.
1940 @param [out] x
1941 X coordinate of the top left corner of the bounding box of the referenced ch aracter.
1942 @param [out] y
1943 Y coordinate of the top left corner of the bounding box of the referenced ch aracter.
1944 @param [out] width
1945 Width of the bounding box of the referenced character.
1946 @param [out] height
1947 Height of the bounding box of the referenced character.
1948 @retval S_OK
1949 @retval E_INVALIDARG if bad [in] passed, [out] values are 0s
1950 */
1951 [propget] HRESULT characterExtents
1952 (
1953 [in] long offset,
1954 [in] enum IA2CoordinateType coordType,
1955 [out] long *x,
1956 [out] long *y,
1957 [out] long *width,
1958 [out, retval] long *height
1959 );
1960
1961
1962 /** @brief Returns the number of active non-contiguous selections
1963 @param [out] nSelections
1964 @retval S_OK
1965 */
1966 [propget] HRESULT nSelections
1967 (
1968 [out, retval] long *nSelections
1969 );
1970
1971 /** @brief Returns the text position for the specified screen position.
1972
1973 Given a point return the zero-based index of the character under that
1974 point. The same functionality could be achieved by using the bounding
1975 boxes for each character as returned by IAccessibleText::characterExtents.
1976 The method IAccessibleText::offsetAtPoint, however, can be implemented
1977 more efficiently.
1978
1979 @param [in] x
1980 The position's x value for which to look up the index of the character that
1981 is rendered on to the display at that point.
1982 @param [in] y
1983 The position's y value for which to look up the index of the character that
1984 is rendered on to the display at that point.
1985 @param [in] coordType
1986 Screen coordinates or window coordinates.
1987 @param [out] offset
1988 Index of the character under the given point or -1 if the point
1989 is invalid or there is no character under the point.
1990 @retval S_OK
1991 @retval E_INVALIDARG if bad [in] passed, [out] value is 0
1992 */
1993 [propget] HRESULT offsetAtPoint
1994 (
1995 [in] long x,
1996 [in] long y,
1997 [in] enum IA2CoordinateType coordType,
1998 [out, retval] long *offset
1999 );
2000
2001 /** @brief Returns the character offsets of Nth active text selection
2002 @param [in] selectionIndex
2003 Index of selection (0 based).
2004 @param [out] startOffset
2005 0 based offset of first selected character
2006 @param [out] endOffset
2007 0 based offset of one past the last selected character.
2008 @retval S_OK
2009 @retval S_FALSE if there is nothing to return, [out] values are 0s
2010 @retval E_INVALIDARG if bad [in] passed, [out] values are 0s
2011 */
2012 [propget] HRESULT selection
2013 (
2014 [in] long selectionIndex,
2015 [out] long *startOffset,
2016 [out, retval] long *endOffset
2017 );
2018
2019 /** @brief Returns the substring between the two given indices.
2020
2021 The substring starts with the character at startOffset (inclusive) and up to
2022 the character at endOffset (exclusive), if startOffset is less or equal
2023 endOffste. If endOffset is lower than startOffset, the result is the same
2024 as a call with the two arguments being exchanged.
2025
2026 The whole text can be requested by passing the indices zero and
2027 IAccessibleText::nCharacters. If both indices have the same value, an empty
2028 string is returned.
2029 @param [in] startOffset
2030 Index of the first character to include in the returned string. The valid ra nge
2031 is 0..length.
2032 @param [in] endOffset
2033 Index of the last character to exclude in the returned string. The valid ran ge
2034 is 0..length.
2035 @param [out] text
2036 Returns the substring starting with the character at startOffset (inclusive)
2037 and up to the character at endOffset (exclusive), if startOffset is less tha n
2038 or equal to endOffset.
2039 @retval S_OK
2040 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
2041 @note The returned string may be longer than endOffset-startOffset bytes if t ext
2042 contains multi-byte characters.
2043 */
2044 [propget] HRESULT text
2045 (
2046 [in] long startOffset,
2047 [in] long endOffset,
2048 [out, retval] BSTR *text
2049 );
2050
2051 /** @brief Returns a text portion before the given position.
2052
2053 Returns the substring of the specified text type that is located before the
2054 given character and does not include it. The result of this method should be
2055 same as a result for IAccessibleText::textAtOffset with a suitably decreased
2056 index value.
2057
2058 For example, if text type is ::IA2_TEXT_BOUNDARY_WORD, then the complete
2059 word that is closest to and located before offset is returned.
2060
2061 If the index is valid, but no suitable word (or other boundary type) is found , a
2062 NULL pointer is returned.
2063
2064 @param [in] offset
2065 Index of the character for which to return the text part before it. The ind ex
2066 character will not be part of the returned string. The valid range is 0..len gth.
2067 @param [in] boundaryType
2068 The type of the text portion to return. See ::IA2TextBoundaryType for the
2069 complete list.
2070 @param [out] startOffset
2071 0 based offset of first character.
2072 @param [out] endOffset
2073 0 based offset of one past the last character.
2074 @param [out] text
2075 Returns the requested text portion. This portion may be empty or invalid wh en
2076 no appropriate text portion is found or text type is invalid.
2077 @retval S_OK
2078 @retval S_FALSE if the requested boundary type is not implemented, such as
2079 ::IA2_TEXT_BOUNDARY_SENTENCE, or if there is nothing to return;
2080 [out] values are 0s and NULL respectively
2081 @retval E_INVALIDARG if bad [in] passed, [out] values are 0s and NULL respect ively
2082 */
2083 [propget] HRESULT textBeforeOffset
2084 (
2085 [in] long offset,
2086 [in] enum IA2TextBoundaryType boundaryType,
2087 [out] long *startOffset,
2088 [out] long *endOffset,
2089 [out, retval] BSTR *text
2090 );
2091
2092 /** @brief Returns a text portion after the given position.
2093
2094 Returns the substring of the specified text type that is located after the
2095 given character and does not include it. The result of this method should be
2096 same as a result for IAccessibleText::textAtOffset with a suitably increased
2097 index value.
2098
2099 For example, if text type is ::IA2_TEXT_BOUNDARY_WORD, then the complete
2100 word that is closest to and located after offset is returned.
2101
2102 If the index is valid, but no suitable word (or other text type) is found, a
2103 NULL pointer is returned.
2104
2105 @param [in] offset
2106 Index of the character for which to return the text part before it. The ind ex
2107 character will not be part of the returned string. The valid range is 0..len gth.
2108 @param [in] boundaryType
2109 The type of the text portion to return. See ::IA2TextBoundaryType for the c omplete
2110 list.
2111 @param [out] startOffset
2112 0 based offset of first character.
2113 @param [out] endOffset
2114 0 based offset of one past the last character.
2115 @param [out] text
2116 Returns the requested text portion. This portion may be empty or invalid wh en
2117 no appropriate text portion is found or text type is invalid.
2118 @retval S_OK
2119 @retval S_FALSE if the requested boundary type is not implemented, such as
2120 ::IA2_TEXT_BOUNDARY_SENTENCE, or if there is nothing to return;
2121 [out] values are 0s and NULL respectively
2122 @retval E_INVALIDARG if bad [in] passed, [out] values are 0s and NULL respect ively
2123 */
2124 [propget] HRESULT textAfterOffset
2125 (
2126 [in] long offset,
2127 [in] enum IA2TextBoundaryType boundaryType,
2128 [out] long *startOffset,
2129 [out] long *endOffset,
2130 [out, retval] BSTR *text
2131 );
2132
2133 /** @brief Returns a text portion that spans the given position.
2134
2135 Returns the substring of the specified text type at the specified offset.
2136
2137 If the index is valid, but no suitable word (or other text type) is found, a
2138 NULL pointer is returned.
2139
2140 @param [in] offset
2141 Index of the character for which to return the text part before it. The ind ex
2142 character will not be part of the returned string. The valid range is 0..len gth.
2143 @param [in] boundaryType
2144 The type of the text portion to return. See ::IA2TextBoundaryType for the c omplete
2145 list.
2146 @param [out] startOffset
2147 0 based offset of first character.
2148 @param [out] endOffset
2149 0 based offset of one past the last character.
2150 @param [out] text
2151 Returns the requested text portion. This portion may be empty or invalid wh en
2152 no appropriate text portion is found or text type is invalid.
2153 @retval S_OK
2154 @retval S_FALSE if the requested boundary type is not implemented, such as
2155 ::IA2_TEXT_BOUNDARY_SENTENCE, or if there is nothing to return;
2156 [out] values are 0s and NULL respectively
2157 @retval E_INVALIDARG if bad [in] passed, [out] values are 0s and NULL respect ively
2158 */
2159 [propget] HRESULT textAtOffset
2160 (
2161 [in] long offset,
2162 [in] enum IA2TextBoundaryType boundaryType,
2163 [out] long *startOffset,
2164 [out] long *endOffset,
2165 [out, retval] BSTR *text
2166 );
2167
2168 /** @brief Unselects a range of text.
2169 @param [in] selectionIndex
2170 Index of selection to remove (0 based).
2171 @retval S_OK
2172 @retval E_INVALIDARG if bad [in] passed
2173 */
2174 HRESULT removeSelection
2175 (
2176 [in] long selectionIndex
2177 );
2178
2179 /** @brief Sets the position of the caret.
2180
2181 The caret position/offset is that of the character logically following it,
2182 e.g. to the right of it in a left to right language.
2183
2184 Setting the caret position may or may not alter the current selection. A
2185 change of the selection is notified to the accessibility event listeners wit h
2186 an ::IA2_EVENT_TEXT_SELECTION_CHANGED event.
2187
2188 When the new caret position differs from the old one (which, of course, is th e
2189 standard case) this is notified to the accessibility event listeners with an
2190 ::IA2_EVENT_TEXT_CARET_MOVED event.
2191 @param [in] offset
2192 The new index of the caret. This caret is actually placed to the left side of
2193 the character with that index. An index of 0 places the caret so that the n ext
2194 insertion goes before the first character. An index of IAccessibleText::nCh aracters
2195 leads to insertion after the last character.
2196 @retval S_OK
2197 @retval E_FAIL if the caret cannot be set
2198 @retval E_INVALIDARG if bad [in] passed
2199 */
2200 HRESULT setCaretOffset
2201 (
2202 [in] long offset
2203 );
2204
2205 /** @brief Changes the bounds of an existing selection.
2206 @param [in] selectionIndex
2207 Index of selection to change (0 based)
2208 @param [in] startOffset
2209 New starting offset (0 based)
2210 @param [in] endOffset
2211 New ending offset (0 based) - the offset of the character just past the last character of the selection.
2212 @retval S_OK
2213 @retval E_INVALIDARG if bad [in] passed
2214 */
2215 HRESULT setSelection
2216 (
2217 [in] long selectionIndex,
2218 [in] long startOffset,
2219 [in] long endOffset
2220 );
2221
2222 /** @brief Returns total number of characters.
2223
2224 Note that this may be different than the total number of bytes required to st ore the
2225 text, if the text contains multi-byte characters.
2226 @param [out] nCharacters
2227 @retval S_OK
2228 */
2229 [propget] HRESULT nCharacters
2230 (
2231 [out, retval] long *nCharacters
2232 );
2233
2234 /** @brief Makes a specific part of string visible on screen.
2235 @param [in] startIndex
2236 0 based character offset.
2237 @param [in] endIndex
2238 0 based character offset - the offset of the character just past the last ch aracter of the string.
2239 @param [in] scrollType
2240 Defines where the object should be placed on the screen.
2241 @retval S_OK
2242 @retval E_INVALIDARG if bad [in] passed
2243 */
2244 HRESULT scrollSubstringTo
2245 (
2246 [in] long startIndex,
2247 [in] long endIndex,
2248 [in] enum IA2ScrollType scrollType
2249 );
2250
2251 /** @brief Moves the top left of a substring to a specified location.
2252
2253 @param [in] startIndex
2254 0 based character offset.
2255 @param [in] endIndex
2256 0 based character offset - the offset of the character just past the last ch aracter of the string.
2257 @param [in] coordinateType
2258 Specifies whether the coordinates are relative to the screen or the parent o bject.
2259 @param [in] x
2260 Defines the x coordinate.
2261 @param [in] y
2262 Defines the y coordinate.
2263 @retval S_OK
2264 @retval S_FALSE if the object is already at the specified location.
2265 @retval E_INVALIDARG if bad [in] passed
2266 */
2267 HRESULT scrollSubstringToPoint
2268 (
2269 [in] long startIndex,
2270 [in] long endIndex,
2271 [in] enum IA2CoordinateType coordinateType,
2272 [in] long x,
2273 [in] long y
2274 );
2275
2276 /** @brief Returns any inserted text.
2277
2278 Provided for use by the ::IA2_EVENT_TEXT_INSERTED and ::IA2_EVENT_TEXT_UPDATE D
2279 event handlers.
2280
2281 This data is only guaranteed to be valid while the thread notifying the event
2282 continues. Once the handler has returned, the validity of the data depends on
2283 how the server manages the life cycle of its objects. Also, note that the ser ver
2284 may have different life cycle management strategies for controls depending on
2285 whether or not a control manages its children. Lists, trees, and tables can h ave
2286 a large number of children and thus it's possible that the child objects for those
2287 controls would only be created as needed. Servers should document their life cycle
2288 strategy as this will be of interest to assistive technology or script engine s
2289 accessing data out of process or from other threads. Servers only need to sav e the
2290 last inserted block of text and a scope of the entire application is adequate .
2291
2292 @param [out] newText
2293 The text that was just inserted.
2294 @retval S_OK
2295 @retval S_FALSE if there is nothing to return, [out] value is NULL
2296 */
2297 [propget] HRESULT newText
2298 (
2299 [out, retval] IA2TextSegment *newText
2300 );
2301
2302 /** @brief Returns any removed text.
2303
2304 Provided for use by the IA2_EVENT_TEXT_REMOVED/UPDATED event handlers.
2305
2306 This data is only guaranteed to be valid while the thread notifying the event
2307 continues. Once the handler has returned, the validity of the data depends on
2308 how the server manages the life cycle of its objects. Also, note that the ser ver
2309 may have different life cycle management strategies for controls depending on
2310 whether or not a control manages its children. Lists, trees, and tables can h ave
2311 a large number of children and thus it's possible that the child objects for those
2312 controls would only be created as needed. Servers should document their life cycle
2313 strategy as this will be of interest to assistive technology or script engine s
2314 accessing data out of process or from other threads. Servers only need to sav e the
2315 last removed block of text and a scope of the entire application is adequate.
2316
2317 @param [out] oldText
2318 The text that was just removed.
2319 @retval S_OK
2320 @retval S_FALSE if there is nothing to return, [out] value is NULL
2321 */
2322 [propget] HRESULT oldText
2323 (
2324 [out, retval] IA2TextSegment *oldText
2325 );
2326
2327 }
2328 /*************************************************************************
2329 *
2330 * File Name (AccessibleEditableText.idl)
2331 *
2332 * IAccessible2 IDL Specification
2333 *
2334 * Copyright (c) Linux Foundation 2007, 2008
2335 * Copyright (c) IBM Corp. 2006
2336 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
2337 *
2338 * This library is free software; you can redistribute it and/or
2339 * modify it under the terms of the GNU Lesser General Public
2340 * License version 2.1, as published by the Free Software Foundation; either
2341 * version 2.1 of the License, or (at your option) any later version.
2342 *
2343 * This library is distributed in the hope that it will be useful,
2344 * but WITHOUT ANY WARRANTY; without even the implied warranty of
2345 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
2346 * Lesser General Public License for more details.
2347 *
2348 * You should have received a copy of the GNU Lesser General Public
2349 * License along with this library; if not, write to the Free Software
2350 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 U SA
2351 *
2352 ************************************************************************/
2353
2354 import "objidl.idl";
2355 import "oaidl.idl";
2356 import "oleacc.idl";
2357
2358
2359 /** @brief This interface provides clipboard capability to text objects.
2360
2361 This interface is typically used in conjunction with the IAccessibleText
2362 interface and complements that interface with the additional capability of
2363 clipboard operations. Note that even a read only text object can support
2364 the copy capability so this interface is not limited to editable objects.
2365
2366 The substrings used with this interface are specified as follows:
2367 If startOffset is less than endOffset, the substring starts with the
2368 character at startOffset and ends with the character just before endOffset.
2369 If endOffset is lower than startOffset, the result is the same as a call
2370 with the two arguments exchanged. The whole text can be defined by passing
2371 the indices zero and IAccessibleText::nCharacters. If both indices have the
2372 same value, an empty string is defined.
2373
2374 Refer to the @ref _specialOffsets
2375 "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Me thods"
2376 for information about a special offset constant that can be used in %IAccessib leEditableText methods.
2377 */
2378 [object, uuid(A59AA09A-7011-4b65-939D-32B1FB5547E3)]
2379 interface IAccessibleEditableText : IUnknown
2380 {
2381
2382 /** @brief Copies the text range into the clipboard.
2383
2384 The specified text between the two given indices is copied into the
2385 system clipboard.
2386
2387 @param [in] startOffset
2388 Start index of the text to moved into the clipboard.
2389 The valid range is 0..length.
2390 @param [in] endOffset
2391 End index of the text to moved into the clipboard.
2392 The valid range is 0..length.
2393 @retval S_OK
2394 @retval E_INVALIDARG if bad [in] passed
2395 */
2396 HRESULT copyText
2397 (
2398 [in] long startOffset,
2399 [in] long endOffset
2400 );
2401
2402 /** @brief Deletes a range of text.
2403
2404 The text between and including the two given indices is deleted
2405 from the text represented by this object.
2406
2407 @param [in] startOffset
2408 Start index of the text to be deleted.
2409 The valid range is 0..length.
2410 @param [in] endOffset
2411 End index of the text to be deleted.
2412 The valid range is 0..length.
2413 @retval S_OK
2414 @retval E_INVALIDARG if bad [in] passed
2415 */
2416 HRESULT deleteText
2417 (
2418 [in] long startOffset,
2419 [in] long endOffset
2420 );
2421
2422 /** @brief Inserts text at the specified position.
2423
2424 The specified string is inserted at the given index into the text
2425 represented by this object.
2426
2427 @param [in] offset
2428 Index at which to insert the text.
2429 The valid range is 0..length.
2430 @param [in] text
2431 Text that is inserted.
2432 @retval S_OK
2433 @retval E_INVALIDARG if bad [in] passed
2434 */
2435 HRESULT insertText
2436 (
2437 [in] long offset,
2438 [in] BSTR *text
2439 );
2440
2441 /** @brief Deletes a range of text and copies it to the clipboard.
2442
2443 The text between the two given indices is deleted from the text
2444 represented by this object and copied to the clipboard.
2445
2446 @param [in] startOffset
2447 Start index of the text to be deleted.
2448 The valid range is 0..length.
2449 @param [in] endOffset
2450 End index of the text to be deleted.
2451 The valid range is 0..length.
2452 @retval S_OK
2453 @retval E_INVALIDARG if bad [in] passed
2454 */
2455 HRESULT cutText
2456 (
2457 [in] long startOffset,
2458 [in] long endOffset
2459 );
2460
2461 /** @brief Pastes text from the clipboard.
2462
2463 The text in the system clipboard is pasted into the text represented
2464 by this object at the given index. This method is similar to the
2465 IAccessibleEditableText::insertText method. If the index is not valid
2466 the system clipboard text is not inserted.
2467
2468 @param [in] offset
2469 Index at which to insert the text from the system clipboard into
2470 the text represented by this object.
2471 The valid range is 0..length.
2472 @retval S_OK
2473 @retval E_INVALIDARG if bad [in] passed
2474 */
2475 HRESULT pasteText
2476 (
2477 [in] long offset
2478 );
2479
2480 /** @brief Replaces text.
2481
2482 The text between the two given indices is replaced by the specified
2483 replacement string. This method is equivalent to calling first
2484 IAccessibleEditableText::deleteText with the two indices and then
2485 calling IAccessibleEditableText::insertText with the replacement text
2486 at the start index.
2487
2488 @param [in] startOffset
2489 Start index of the text to be replaced.
2490 The valid range is 0..length.
2491 @param [in] endOffset
2492 Start index of the text to be replaced.
2493 The valid range is 0..length.
2494 @param [in] text
2495 The Text that replaces the text between the given indices.
2496 @retval S_OK
2497 @retval E_INVALIDARG if bad [in] passed
2498 */
2499 HRESULT replaceText
2500 (
2501 [in] long startOffset,
2502 [in] long endOffset,
2503 [in] BSTR *text
2504 );
2505
2506 /** @brief Replaces the attributes of a text range by the given set of attribu tes.
2507
2508 Sets the attributes for the text between the two given indices. The old
2509 attributes are replaced by the new list of attributes.
2510
2511 @param [in] startOffset
2512 Start index of the text whose attributes are modified.
2513 The valid range is 0..length.
2514 @param [in] endOffset
2515 Start index of the text whose attributes are modified.
2516 The valid range is 0..length.
2517 @param [in] attributes
2518 Set of attributes that replaces the old list of attributes of
2519 the specified text portion.
2520 @retval S_OK
2521 @retval E_INVALIDARG if bad [in] passed
2522 */
2523 HRESULT setAttributes
2524 (
2525 [in] long startOffset,
2526 [in] long endOffset,
2527 [in] BSTR *attributes
2528 );
2529 }
2530
2531 /*************************************************************************
2532 *
2533 * File Name (AccessibleHyperlink.idl)
2534 *
2535 * IAccessible2 IDL Specification
2536 *
2537 * Copyright (c) Linux Foundation 2007, 2008
2538 * Copyright (c) IBM Corp. 2006
2539 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
2540 *
2541 * This library is free software; you can redistribute it and/or
2542 * modify it under the terms of the GNU Lesser General Public
2543 * License version 2.1, as published by the Free Software Foundation; either
2544 * version 2.1 of the License, or (at your option) any later version.
2545 *
2546 * This library is distributed in the hope that it will be useful,
2547 * but WITHOUT ANY WARRANTY; without even the implied warranty of
2548 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
2549 * Lesser General Public License for more details.
2550 *
2551 * You should have received a copy of the GNU Lesser General Public
2552 * License along with this library; if not, write to the Free Software
2553 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02110-1301 USA
2554 *
2555 ************************************************************************/
2556
2557 import "objidl.idl";
2558 import "oaidl.idl";
2559 import "oleacc.idl";
2560
2561
2562 /** @brief This interface represents hyperlinks.
2563
2564 This interface represents a hyperlink associated with a single substring
2565 of text or single non-text object. Non-text objects can have either a
2566 single link or a collection of links such as when the non-text object is
2567 an image map.
2568
2569 Linked objects and anchors are implementation dependent. This interface is deri ved
2570 from IAccessibleAction. IAccessibleAction::nActions is one greater than the
2571 maximum value for the indices used with the methods of this interface.
2572
2573 Furthermore, the object that implements this interface has to be connected
2574 implicitly or explicitly with an object that implements IAccessibleText.
2575 IAccessibleHyperlink::startIndex and IAccessibleHyperlink::endIndex are
2576 indices with respect to the text exposed by IAccessibleText.
2577
2578 This interface provides access to a single object which can have multiple actio ns.
2579 An example is an image map which is an image with multiple links each of which is
2580 associated with a separate non-overlapping area of the image. This interface could
2581 also be applied to other kinds of objects with multiple actions such as "smart tags"
2582 which are objects, typically strings, which have multiple actions such as
2583 "Activate URI", "Bookmark URI", etc.
2584
2585 An interesting use case is an image map where each area is associated with mult iple
2586 actions, e.g. an image map of smart tags. In this case you would have to impl ement
2587 two levels of accessible hyperlinks. The first level hyperlinks would only im plement
2588 anchor and anchorTarget. The anchors would all reference the image object. T he
2589 anchorTargets would reference the second level accessible hyperlink objects. None
2590 of the IAccessibleAction methods would be implemented on the first level hyper link
2591 objects. The second level hyperlink objects would implement the IAccessibleAc tion
2592 methods. Their anchors would also reference the image object and their anchor Targets
2593 would reference URLs or the objects that would be activated.
2594
2595 This use case demonstrates that in some cases there is no need for IAccessibleH yperlink
2596 to derive from IAccessibleAction. As a result it may be removed in a later ve rsion of
2597 the IDL and it is suggested that implementations should not rely on the inheri tance.
2598
2599 */
2600 [object, uuid(01C20F2B-3DD2-400f-949F-AD00BDAB1D41)]
2601 interface IAccessibleHyperlink : IAccessibleAction
2602 {
2603
2604 /** @brief Returns an object that represents the link anchor, as appropriate
2605 for the link at the specified index.
2606 @param [in] index
2607 A 0 based index identifies the anchor when, as in the case of an image map,
2608 there is more than one link represented by this object. The valid maximal
2609 index is indicated by IAccessibleAction::nActions.
2610 @param [out] anchor
2611 This is an implementation dependent value. For example, for a text link thi s
2612 method could return the substring of the containing string where the sub string
2613 is overridden with link behavior, and for an image link this method coul d return
2614 an IUnknown VARIANT for IAccessibleImage. See the section about
2615 @ref _variants "VARIANTs" for additional information.
2616 @retval S_OK
2617 @retval S_FALSE if there is nothing to return, [out] value is NULL
2618 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
2619 */
2620 [propget] HRESULT anchor
2621 (
2622 [in] long index,
2623 [out, retval] VARIANT *anchor
2624 );
2625
2626 /** @brief Returns an object representing the target of the link, as appropria te
2627 for the link at the specified index.
2628 @param [in] index
2629 A 0 based index identifies the anchor when, as in the case of an image map,
2630 there is more than one link represented by this object. The valid maximal
2631 index is indicated by IAccessibleAction::nActions.
2632 @param [out] anchorTarget
2633 This is an implementation dependent value. For example this method could
2634 return a BSTR VARIANT of the URI. Alternatively this method could retur n an
2635 IUnknown VARIANT of a COM interface representing a target object to be
2636 activated when the link is activated. See the section about
2637 @ref _variants "VARIANTs" for additional information.
2638 @retval S_OK
2639 @retval S_FALSE if there is nothing to return, [out] value is NULL
2640 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
2641 */
2642 [propget] HRESULT anchorTarget
2643 (
2644 [in] long index,
2645 [out, retval] VARIANT *anchorTarget
2646 );
2647
2648 /** @brief Returns the 0 based character offset at which the textual represent ation of the hyperlink starts.
2649
2650 The returned value is related to the IAccessibleText interface of the object that
2651 owns this hyperlink.
2652 @param [out] index
2653 @retval S_OK
2654 */
2655 [propget] HRESULT startIndex
2656 (
2657 [out, retval] long *index
2658 );
2659
2660 /** @brief Returns the 0 based character offset at which the textual represent ation of the hyperlink ends.
2661
2662 The returned value is related to the IAccessibleText interface of the object that
2663 owns this hyperlink. The character at the index is not part of the hypertext.
2664 @param [out] index
2665 @retval S_OK
2666 */
2667 [propget] HRESULT endIndex
2668 (
2669 [out, retval] long *index
2670 );
2671
2672 /** @brief Returns whether the target object referenced by this link is still valid.
2673
2674 This is a volatile state that may change without sending an appropriate event .
2675 Returns TRUE if the referenced target is still valid and FALSE otherwise.
2676
2677 This has also been used to indicate whether or not the URI of the anchorTarge t
2678 is malformed.
2679
2680 Note: This method is not being used, is deprecated, and should not be impleme nted or
2681 used. It is likely that this method will be removed in a later version of th e IDL.
2682
2683 @param [out] valid
2684 @retval S_OK
2685 @retval S_FALSE if there is nothing to return, [out] value is FALSE
2686 */
2687 [propget] HRESULT valid
2688 (
2689 [out, retval] boolean *valid
2690 );
2691 }
2692 /*************************************************************************
2693 *
2694 * File Name (AccessibleHypertext.idl)
2695 *
2696 * IAccessible2 IDL Specification
2697 *
2698 * Copyright (c) Linux Foundation 2007, 2008
2699 * Copyright (c) IBM Corp. 2006
2700 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
2701 *
2702 * This library is free software; you can redistribute it and/or
2703 * modify it under the terms of the GNU Lesser General Public
2704 * License version 2.1, as published by the Free Software Foundation; either
2705 * version 2.1 of the License, or (at your option) any later version.
2706 *
2707 * This library is distributed in the hope that it will be useful,
2708 * but WITHOUT ANY WARRANTY; without even the implied warranty of
2709 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
2710 * Lesser General Public License for more details.
2711 *
2712 * You should have received a copy of the GNU Lesser General Public
2713 * License along with this library; if not, write to the Free Software
2714 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02110-1301 USA
2715 *
2716 ************************************************************************/
2717
2718 import "objidl.idl";
2719 import "oaidl.idl";
2720 import "oleacc.idl";
2721
2722
2723
2724 /** @brief This interface exposes information about hypertext in a document.
2725
2726 The %IAccessibleHypertext interface is the main interface to expose
2727 hyperlinks in a document, typically a text document, that are used
2728 to reference other documents. A typical implementation is to implement
2729 this interface on the smallest text object such as a paragraph of text.
2730 */
2731 [object, uuid(6B4F8BBF-F1F2-418a-B35E-A195BC4103B9)]
2732 interface IAccessibleHypertext : IAccessibleText
2733 {
2734
2735 /** @brief Returns the number of links and link groups contained within this h ypertext
2736 paragraph.
2737 @param [out] hyperlinkCount
2738 The number of links and link groups within this hypertext paragraph.
2739 Returns 0 if there is no link.
2740 @retval S_OK
2741 */
2742 [propget] HRESULT nHyperlinks
2743 (
2744 [out, retval] long *hyperlinkCount
2745 );
2746
2747 /** @brief Returns the specified link.
2748
2749 The returned IAccessibleHyperlink object encapsulates the hyperlink and
2750 provides several kinds of information describing it.
2751 @param [in] index
2752 This 0 based index specifies the hyperlink to return.
2753 @param [out] hyperlink
2754 If the given index is valid, i.e. lies in the interval from 0 to the number
2755 of links minus one, a reference to the specified hyperlink object is returne d.
2756 If the index is invalid then a NULL pointer is returned.
2757 @retval S_OK
2758 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
2759 */
2760 [propget] HRESULT hyperlink
2761 (
2762 [in] long index,
2763 [out, retval] IAccessibleHyperlink **hyperlink
2764 );
2765
2766 /** @brief Returns the index of the hyperlink that is associated with this cha racter index.
2767
2768 This is the case when a link spans the given character index.
2769 @param [in] charIndex
2770 A 0 based index of the character for which to return the link index. If
2771 IAccessibleText is used to represent the text containing the link, then the
2772 character index is only valid if it is greater than or equal to zero an d
2773 lower than the number of characters in the text.
2774 @param [out] hyperlinkIndex
2775 Returns the 0 based index of the hyperlink that is associated with this
2776 character index, or -1 if charIndex is not on a link.
2777 @retval S_OK
2778 @retval S_FALSE if there is nothing to return, [out] value is -1
2779 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
2780 */
2781 [propget] HRESULT hyperlinkIndex
2782 (
2783 [in] long charIndex,
2784 [out, retval] long *hyperlinkIndex
2785 );
2786
2787 }
2788 /*************************************************************************
2789 *
2790 * File Name (AccessibleTable.idl)
2791 *
2792 * IAccessible2 IDL Specification
2793 *
2794 * Copyright (c) Linux Foundation 2007, 2009
2795 * Copyright (c) IBM Corp. 2006
2796 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
2797 *
2798 * This library is free software; you can redistribute it and/or
2799 * modify it under the terms of the GNU Lesser General Public
2800 * License version 2.1, as published by the Free Software Foundation; either
2801 * version 2.1 of the License, or (at your option) any later version.
2802 *
2803 * This library is distributed in the hope that it will be useful,
2804 * but WITHOUT ANY WARRANTY; without even the implied warranty of
2805 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
2806 * Lesser General Public License for more details.
2807 *
2808 * You should have received a copy of the GNU Lesser General Public
2809 * License along with this library; if not, write to the Free Software
2810 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 U SA
2811 *
2812 ************************************************************************/
2813
2814 import "objidl.idl";
2815 import "oaidl.idl";
2816 import "oleacc.idl";
2817
2818
2819
2820 /** @brief This interface gives access to a two-dimensional table.
2821
2822 Typically all accessible objects that represent cells or cell-clusters of a tab le
2823 will be at the same time children of the table. In this case IAccessible2::in dexInParent
2824 will return the child index which then can be used when calling IAccessibleTab le::rowIndex
2825 and IAccessibleTable::columnIndex.
2826
2827 However, in some cases that kind of implementation will not be possible. When
2828 the table cells are not direct children of a table, the object representing
2829 the cell can define a "table-cell-index" object attribute identifying the 0
2830 based table cell index. This object attribute is obtained by parsing the
2831 attribute string returned by IAccessible2::attributes. The "table-cell-index"
2832 attribute can be used just like a child index of the typical case. ATs should
2833 first test for the presence of the "table-cell-index" attribute and if it is n ot
2834 present then IAccessible2::indexInParent can be used as in the typical case
2835 where cells are direct children of the table.
2836
2837 The range of valid coordinates for this interface are implementation dependent.
2838 However, that range includes at least the intervals from the from the first ro w
2839 or column with the index 0 up to the last (but not including) used row or colu mn
2840 as returned by IAccessibleTable::nRows and IAccessibleTable::nColumns.
2841
2842 Note that newer implementations are now using IAccessibleTable2 and IAccessible TableCell
2843 rather than this interface.
2844 */
2845 [object, uuid(35AD8070-C20C-4fb4-B094-F4F7275DD469)]
2846 interface IAccessibleTable : IUnknown
2847 {
2848
2849 /** @brief Returns the accessible object at the specified row and column in
2850 the table. This object could be an IAccessible or an IAccessible2.
2851 @param [in] row
2852 The 0 based row index for which to retrieve the cell.
2853 @param [in] column
2854 The 0 based column index for which to retrieve the cell.
2855 @param [out] accessible
2856 If both row and column index are valid then the corresponding accessible
2857 object is returned that represents the requested cell regardless of whether
2858 the cell is currently visible (on the screen).
2859 @retval S_OK
2860 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
2861 */
2862 [propget] HRESULT accessibleAt
2863 (
2864 [in] long row,
2865 [in] long column,
2866 [out, retval] IUnknown **accessible
2867 );
2868
2869 /** @brief Returns the caption for the table. The returned object could be
2870 an IAccessible or an IAccessible2.
2871 @param [out] accessible
2872 If the table has a caption then a reference to it is returned, else a NULL
2873 pointer is returned.
2874 @retval S_OK
2875 @retval S_FALSE if there is nothing to return, [out] value is NULL
2876 */
2877 [propget] HRESULT caption
2878 (
2879 [out, retval] IUnknown **accessible
2880 );
2881
2882 /** @brief Translates the given row and column indexes into the corresponding cell index.
2883 @param [in] rowIndex
2884 0 based row index for the cell.
2885 @param [in] columnIndex
2886 0 based column index for the cell.
2887 @param [out] cellIndex
2888 Returns the 0 based index of the cell at the specified row and column indexe s.
2889 @retval S_OK
2890 @retval E_INVALIDARG if bad [in] passed, [out] value is 0
2891 @note The returned value is not necessarily a child index of the immediate pa rent.
2892 In cases where the table cells are not direct children of the table the inde x
2893 is actually the cell index, i.e. conceptually it's an index into a one dimen sional
2894 array of cells laid out in row order.
2895 */
2896 [propget] HRESULT childIndex
2897 (
2898 [in] long rowIndex,
2899 [in] long columnIndex,
2900 [out, retval] long *cellIndex
2901 );
2902
2903 /** @brief Returns the description text of the specified column in the table.
2904 @param [in] column
2905 The 0 based index of the column for which to retrieve the description.
2906 @param [out] description
2907 Returns the description text of the specified column in the table if such a
2908 description exists. Otherwise a NULL pointer is returned.
2909 @retval S_OK
2910 @retval S_FALSE if there is nothing to return, [out] value is NULL
2911 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
2912 */
2913 [propget] HRESULT columnDescription
2914 (
2915 [in] long column,
2916 [out, retval] BSTR *description
2917 );
2918
2919 /** @brief Returns the number of columns occupied by the accessible object
2920 at the specified row and column in the table.
2921
2922 The result is greater than 1 if the specified cell spans multiple columns.
2923 @param [in] row
2924 0 based row index of the accessible for which to return the column extent.
2925 @param [in] column
2926 0 based column index of the accessible for which to return the column extent .
2927 @param [out] nColumnsSpanned
2928 Returns the 1 based column extent of the specified cell.
2929 @retval S_OK
2930 @retval E_INVALIDARG if bad [in] passed, [out] value is 0
2931 */
2932 [propget] HRESULT columnExtentAt
2933 (
2934 [in] long row,
2935 [in] long column,
2936 [out, retval] long *nColumnsSpanned
2937 );
2938
2939 /** @brief Returns the column headers as an %IAccessibleTable object.
2940
2941 Content and size of the returned table are implementation dependent.
2942 @param [out] accessibleTable
2943 The column header
2944 @param [out] startingRowIndex
2945 The 0 based row index where the header starts, usually 0.
2946 @retval S_OK
2947 @retval S_FALSE if there is no header, [out] values are NULL and 0 respective ly
2948 */
2949 [propget] HRESULT columnHeader
2950 (
2951 [out] IAccessibleTable **accessibleTable,
2952 [out, retval] long *startingRowIndex
2953 );
2954
2955 /** @brief Translates the given cell index into the corresponding column index .
2956 @param [in] cellIndex
2957 0 based index of the cell in the parent or closest ancestor table. Typicall y this
2958 is the value returned from IAccessible2::indexInParent, but in the case where the
2959 table cells are not direct children of the table this is the cell index specified
2960 by the "table-cell-index" object attribute obtained from parsing the att ributes
2961 string returned by calling IAccessible2::attributes on the cell object.
2962 @param [out] columnIndex
2963 Returns the 0 based column index of the cell of the specified child or the i ndex of
2964 the first column if the child spans multiple columns.
2965 @retval S_OK
2966 @retval E_INVALIDARG if bad [in] passed, [out] value is 0
2967 */
2968 [propget] HRESULT columnIndex
2969 (
2970 [in] long cellIndex,
2971 [out, retval] long *columnIndex
2972 );
2973
2974 /** @brief Returns the total number of columns in table
2975 @param [out] columnCount
2976 Number of columns in table (including columns outside the current viewport)
2977 @retval S_OK
2978 */
2979 [propget] HRESULT nColumns
2980 (
2981 [out, retval] long *columnCount
2982 );
2983
2984 /** @brief Returns the total number of rows in table
2985 @param [out] rowCount
2986 Number of rows in table (including rows outside the current viewport)
2987 @retval S_OK
2988 */
2989 [propget] HRESULT nRows
2990 (
2991 [out, retval] long *rowCount
2992 );
2993
2994 /** @brief Returns the total number of selected cells
2995 @param [out] cellCount
2996 Number of cells currently selected
2997 @retval S_OK
2998 */
2999 [propget] HRESULT nSelectedChildren
3000 (
3001 [out, retval] long *cellCount
3002 );
3003
3004 /** @brief Returns the total number of selected columns
3005 @param [out] columnCount
3006 Number of columns currently selected
3007 @retval S_OK
3008 */
3009 [propget] HRESULT nSelectedColumns
3010 (
3011 [out, retval] long *columnCount
3012 );
3013
3014 /** @brief Returns the total number of selected rows
3015 @param [out] rowCount
3016 Number of rows currently selected
3017 @retval S_OK
3018 */
3019 [propget] HRESULT nSelectedRows
3020 (
3021 [out, retval] long *rowCount
3022 );
3023
3024 /** @brief Returns the description text of the specified row in the table.
3025 @param [in] row
3026 The 0 based index of the row for which to retrieve the description.
3027 @param [out] description
3028 Returns the description text of the specified row in the table if such a
3029 description exists. Otherwise a NULL pointer is returned.
3030 @retval S_OK
3031 @retval S_FALSE if there is nothing to return, [out] value is NULL
3032 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
3033 */
3034 [propget] HRESULT rowDescription
3035 (
3036 [in] long row,
3037 [out, retval] BSTR *description
3038 );
3039
3040 /** @brief Returns the number of rows occupied by the accessible object
3041 at the specified row and column in the table.
3042
3043 The result is greater than 1 if the specified cell spans multiple rows.
3044 @param [in] row
3045 0 based row index of the accessible for which to return the row extent.
3046 @param [in] column
3047 0 based column index of the accessible for which to return the row extent.
3048 @param [out] nRowsSpanned
3049 Returns the row extent of the specified cell.
3050 @retval S_OK
3051 @retval E_INVALIDARG if bad [in] passed, [out] value is 0
3052 */
3053 [propget] HRESULT rowExtentAt
3054 (
3055 [in] long row,
3056 [in] long column,
3057 [out, retval] long *nRowsSpanned
3058 );
3059
3060 /** @brief Returns the row headers as an %IAccessibleTable object.
3061
3062 Content and size of the returned table are implementation dependent.
3063 @param [out] accessibleTable
3064 The row header.
3065 @param [out] startingColumnIndex
3066 The 0 based column index where the header starts, usually 0.
3067 @retval S_OK
3068 @retval S_FALSE if there is no header, [out] values are NULL and 0 respective ly
3069 */
3070 [propget] HRESULT rowHeader
3071 (
3072 [out] IAccessibleTable **accessibleTable,
3073 [out, retval] long *startingColumnIndex
3074 );
3075
3076 /** @brief Translates the given cell index into a row index.
3077 @param [in] cellIndex
3078 0 based index of the cell in the parent or closest ancestor table. Typicall y this
3079 is the value returned from IAccessible2::indexInParent, but in the case where the
3080 table cells are not direct children of the table this is the cell index specified
3081 by the "table-cell-index" object attribute obtained from parsing the att ributes
3082 string returned by calling IAccessible2::attributes on the cell object.
3083 @param [out] rowIndex
3084 0 based row index
3085 @retval S_OK
3086 @retval E_INVALIDARG if bad [in] passed, [out] value is 0
3087 */
3088 [propget] HRESULT rowIndex
3089 (
3090 [in] long cellIndex,
3091 [out, retval] long *rowIndex
3092 );
3093
3094 /** @brief Returns a list of cell indexes currently selected (0 based).
3095 @param [in] maxChildren
3096 This parameter is ignored. Refer to @ref _arrayConsideration
3097 "Special Consideration when using Arrays" for more details.
3098 @param [out] children
3099 An array of cell indexes of selected cells (each index is 0 based),
3100 allocated by the server. Free it with CoTaskMemFree.
3101 @param [out] nChildren
3102 The number of cell indexes returned; the size of the returned array.
3103 @retval S_OK
3104 @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
3105 */
3106 [propget] HRESULT selectedChildren
3107 (
3108 [in] long maxChildren,
3109 [out, size_is(,maxChildren), length_is(,*nChildren)] long **children,
3110 [out, retval] long *nChildren
3111 );
3112
3113 /** @brief Returns a list of column indexes currently selected (0 based).
3114 @param [in] maxColumns
3115 This parameter is ignored. Refer to @ref _arrayConsideration
3116 "Special Consideration when using Arrays" for more details.
3117 @param [out] columns
3118 An array of column indexes of selected columns (each index is 0 based), allocated
3119 by the server. Free it with CoTaskMemFree.
3120 @param [out] nColumns
3121 The number of column indexes returned; the size of the returned array.
3122 @retval S_OK
3123 @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
3124 */
3125 [propget] HRESULT selectedColumns
3126 (
3127 [in] long maxColumns,
3128 [out, size_is(,maxColumns), length_is(,*nColumns)] long **columns,
3129 [out, retval] long *nColumns
3130 );
3131
3132 /** @brief Returns a list of row indexes currently selected (0 based).
3133 @param [in] maxRows
3134 This parameter is ignored. Refer to @ref _arrayConsideration
3135 "Special Consideration when using Arrays" for more details.
3136 @param [out] rows
3137 An array of row indexes of selected rows (each index is 0 based), allocated
3138 by the server. Free it with CoTaskMemFree.
3139 @param [out] nRows
3140 The number of row indexes returned; the size of the returned array.
3141 @retval S_OK
3142 @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
3143 */
3144 [propget] HRESULT selectedRows
3145 (
3146 [in] long maxRows,
3147 [out, size_is(,maxRows), length_is(,*nRows)] long **rows,
3148 [out, retval] long *nRows
3149 );
3150
3151 /** @brief Returns the summary description of the table. The returned object could be
3152 an IAccessible or an IAccessible2.
3153 @param [out] accessible
3154 Returns a reference to an implementation dependent accessible object
3155 representing the table's summary or a NULL pointer if the table
3156 does not support a summary.
3157 @retval S_OK
3158 @retval S_FALSE if there is nothing to return, [out] value is NULL
3159 */
3160 [propget] HRESULT summary
3161 (
3162 [out, retval] IUnknown **accessible
3163 );
3164
3165 /** @brief Returns a boolean value indicating whether the specified column is
3166 completely selected.
3167 @param [in] column
3168 0 based index of the column for which to determine whether it is selected.
3169 @param [out] isSelected
3170 Returns TRUE if the specified column is selected completely and FALSE otherw ise.
3171 @retval S_OK
3172 @retval E_INVALIDARG if bad [in] passed, [out] value is FALSE
3173 */
3174 [propget] HRESULT isColumnSelected
3175 (
3176 [in] long column,
3177 [out, retval] boolean *isSelected
3178 );
3179
3180 /** @brief Returns a boolean value indicating whether the specified row is com pletely
3181 selected.
3182 @param [in] row
3183 0 based index of the row for which to determine whether it is selected.
3184 @param [out] isSelected
3185 Returns TRUE if the specified row is selected completely and FALSE otherwise .
3186 @retval S_OK
3187 @retval E_INVALIDARG if bad [in] passed, [out] value is FALSE
3188 */
3189 [propget] HRESULT isRowSelected
3190 (
3191 [in] long row,
3192 [out, retval] boolean *isSelected
3193 );
3194
3195 /** @brief Returns a boolean value indicating whether the specified cell is se lected.
3196 @param [in] row
3197 0 based index of the row for the cell to determine whether it is selected.
3198 @param [in] column
3199 0 based index of the column for the cell to determine whether it is selected .
3200 @param [out] isSelected
3201 Returns TRUE if the specified cell is selected and FALSE otherwise.
3202 @retval S_OK
3203 @retval E_INVALIDARG if bad [in] passed, [out] value is FALSE
3204 */
3205 [propget] HRESULT isSelected
3206 (
3207 [in] long row,
3208 [in] long column,
3209 [out, retval] boolean *isSelected
3210 );
3211
3212 /** @brief Selects a row and unselects all previously selected rows.
3213 @param [in] row
3214 0 based index of the row to be selected.
3215 @retval S_OK
3216 @retval E_INVALIDARG if bad [in] passed
3217 */
3218 HRESULT selectRow
3219 (
3220 [in] long row
3221 );
3222
3223 /** @brief Selects a column and unselects all previously selected columns.
3224 @param [in] column
3225 0 based index of the column to be selected.
3226 @retval S_OK
3227 @retval E_INVALIDARG if bad [in] passed
3228 */
3229 HRESULT selectColumn
3230 (
3231 [in] long column
3232 );
3233
3234 /** @brief Unselects one row, leaving other selected rows selected (if any).
3235 @param [in] row
3236 0 based index of the row to be unselected.
3237 @retval S_OK
3238 @retval E_INVALIDARG if bad [in] passed
3239 */
3240 HRESULT unselectRow
3241 (
3242 [in] long row
3243 );
3244
3245 /** @brief Unselects one column, leaving other selected columns selected (if a ny).
3246 @param [in] column
3247 0 based index of the column to be unselected.
3248 @retval S_OK
3249 @retval E_INVALIDARG if bad [in] passed
3250 */
3251 HRESULT unselectColumn
3252 (
3253 [in] long column
3254 );
3255
3256 /** @brief Given a cell index, gets the row and column indexes and extents of a cell
3257 and whether or not it is selected.
3258
3259 This is a convenience function. It is not mandatory to implement it.
3260 @param [in] index
3261 0 based index of this cell in the table.
3262 @param [out] row
3263 0 based row index.
3264 @param [out] column
3265 0 based column index.
3266 @param [out] rowExtents
3267 Number of cells spanned by this cell in this row.
3268 @param [out] columnExtents
3269 Number of cells spanned by this cell in this column.
3270 @param [out] isSelected
3271 Indicates if the specified cell is selected.
3272 @retval S_OK
3273 @retval E_INVALIDARG if bad [in] passed, [out] values are 0s and FALSE respec tively
3274 */
3275 [propget] HRESULT rowColumnExtentsAtIndex
3276 (
3277 [in] long index,
3278 [out] long *row,
3279 [out] long *column,
3280 [out] long *rowExtents,
3281 [out] long *columnExtents,
3282 [out, retval] boolean *isSelected
3283 );
3284
3285 /** @brief Returns the type and extents describing how a table changed.
3286
3287 Provided for use by the IA2_EVENT_TABLE_MODEL_CHANGED event handler.
3288
3289 This data is only guaranteed to be valid while the thread notifying the event
3290 continues. Once the handler has returned, the validity of the data depends on
3291 how the server manages the life cycle of its objects. Also, note that the ser ver
3292 may have different life cycle management strategies for controls depending on
3293 whether or not a control manages its children. Lists, trees, and tables can h ave
3294 a large number of children and thus it's possible that the child objects for those
3295 controls would only be created as needed. Servers should document their life cycle
3296 strategy as this will be of interest to assistive technology or script engine s
3297 accessing data out of process or from other threads. Servers only need to sav e the
3298 most recent row and column values associated with the change and a scope of t he
3299 entire application is adequate.
3300
3301 @param [out] modelChange
3302 A struct of (type(insert, delete, update), firstRow, lastRow, firstColumn, l astColumn).
3303 @retval S_OK
3304 @retval S_FALSE if there is nothing to return, [out] value is NULL
3305 */
3306 [propget] HRESULT modelChange
3307 (
3308 [out, retval] IA2TableModelChange *modelChange
3309 );
3310
3311 }
3312 /*************************************************************************
3313 *
3314 * File Name (AccessibleTable2.idl)
3315 *
3316 * IAccessible2 IDL Specification
3317 *
3318 * Copyright (c) Linux Foundation 2007, 2009
3319 * Copyright (c) IBM Corp. 2006
3320 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
3321 *
3322 * This library is free software; you can redistribute it and/or
3323 * modify it under the terms of the GNU Lesser General Public
3324 * License version 2.1, as published by the Free Software Foundation; either
3325 * version 2.1 of the License, or (at your option) any later version.
3326 *
3327 * This library is distributed in the hope that it will be useful,
3328 * but WITHOUT ANY WARRANTY; without even the implied warranty of
3329 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
3330 * Lesser General Public License for more details.
3331 *
3332 * You should have received a copy of the GNU Lesser General Public
3333 * License along with this library; if not, write to the Free Software
3334 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 U SA
3335 *
3336 ************************************************************************/
3337
3338 import "objidl.idl";
3339 import "oaidl.idl";
3340 import "oleacc.idl";
3341
3342
3343
3344 /** @brief This interface gives access to a two-dimensional table.
3345
3346 Please also refer to the IAccessibleTableCell interface.
3347
3348 If you want to support older applications you should also support the
3349 IAccessibleTable inteface.
3350 */
3351 [object, uuid(6167f295-06f0-4cdd-a1fa-02e25153d869)]
3352 interface IAccessibleTable2 : IUnknown
3353 {
3354
3355 /** @brief Returns the accessible object at the specified row and column in
3356 the table. This object could be an IAccessible or an IAccessible2.
3357 @param [in] row
3358 The 0 based row index for which to retrieve the cell.
3359 @param [in] column
3360 The 0 based column index for which to retrieve the cell.
3361 @param [out] cell
3362 If both row and column index are valid then the corresponding accessible
3363 object is returned that represents the requested cell regardless of whether
3364 the cell is currently visible (on the screen).
3365 @retval S_OK
3366 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
3367 */
3368 [propget] HRESULT cellAt
3369 (
3370 [in] long row,
3371 [in] long column,
3372 [out, retval] IUnknown **cell
3373 );
3374
3375 /** @brief Returns the caption for the table. The returned object could be
3376 an IAccessible or an IAccessible2.
3377 @param [out] accessible
3378 If the table has a caption then a reference to it is returned, else a NULL
3379 pointer is returned.
3380 @retval S_OK
3381 @retval S_FALSE if there is nothing to return, [out] value is NULL
3382 */
3383 [propget] HRESULT caption
3384 (
3385 [out, retval] IUnknown **accessible
3386 );
3387
3388 /** @brief Returns the description text of the specified column in the table.
3389 @param [in] column
3390 The 0 based index of the column for which to retrieve the description.
3391 @param [out] description
3392 Returns the description text of the specified column in the table if such a
3393 description exists. Otherwise a NULL pointer is returned.
3394 @retval S_OK
3395 @retval S_FALSE if there is nothing to return, [out] value is NULL
3396 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
3397 */
3398 [propget] HRESULT columnDescription
3399 (
3400 [in] long column,
3401 [out, retval] BSTR *description
3402 );
3403
3404
3405 /** @brief Returns the total number of columns in table
3406 @param [out] columnCount
3407 Number of columns in table (including columns outside the current viewport)
3408 @retval S_OK
3409 */
3410 [propget] HRESULT nColumns
3411 (
3412 [out, retval] long *columnCount
3413 );
3414
3415 /** @brief Returns the total number of rows in table
3416 @param [out] rowCount
3417 Number of rows in table (including rows outside the current viewport)
3418 @retval S_OK
3419 */
3420 [propget] HRESULT nRows
3421 (
3422 [out, retval] long *rowCount
3423 );
3424
3425 /** @brief Returns the total number of selected cells
3426 @param [out] cellCount
3427 Number of cells currently selected
3428 @retval S_OK
3429 */
3430 [propget] HRESULT nSelectedCells
3431 (
3432 [out, retval] long *cellCount
3433 );
3434
3435 /** @brief Returns the total number of selected columns
3436 @param [out] columnCount
3437 Number of columns currently selected
3438 @retval S_OK
3439 */
3440 [propget] HRESULT nSelectedColumns
3441 (
3442 [out, retval] long *columnCount
3443 );
3444
3445 /** @brief Returns the total number of selected rows
3446 @param [out] rowCount
3447 Number of rows currently selected
3448 @retval S_OK
3449 */
3450 [propget] HRESULT nSelectedRows
3451 (
3452 [out, retval] long *rowCount
3453 );
3454
3455 /** @brief Returns the description text of the specified row in the table.
3456 @param [in] row
3457 The 0 based index of the row for which to retrieve the description.
3458 @param [out] description
3459 Returns the description text of the specified row in the table if such a
3460 description exists. Otherwise a NULL pointer is returned.
3461 @retval S_OK
3462 @retval S_FALSE if there is nothing to return, [out] value is NULL
3463 @retval E_INVALIDARG if bad [in] passed, [out] value is NULL
3464 */
3465 [propget] HRESULT rowDescription
3466 (
3467 [in] long row,
3468 [out, retval] BSTR *description
3469 );
3470
3471 /** @brief Returns a list of accessibles currently selected.
3472 @param [out] cells
3473 Pointer to an array of references to selected accessibles. The array is
3474 allocated by the server. Free it with CoTaskMemFree.
3475 @param [out] nSelectedCells
3476 The number of accessibles returned; the size of the returned array.
3477 @retval S_OK
3478 @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
3479 */
3480 [propget] HRESULT selectedCells
3481 (
3482 [out, size_is(,*nSelectedCells,)] IUnknown ***cells,
3483 [out, retval] long *nSelectedCells
3484 );
3485
3486 /** @brief Returns a list of column indexes currently selected (0 based).
3487 @param [out] selectedColumns
3488 A pointer to an array of column indexes of selected columns (each index is
3489 0 based). The array is allocated by the server. Free it with CoTaskMemFree.
3490 @param [out] nColumns
3491 The number of column indexes returned; the size of the returned array.
3492 @retval S_OK
3493 @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
3494 */
3495 [propget] HRESULT selectedColumns
3496 (
3497 [out, size_is(,*nColumns)] long **selectedColumns,
3498 [out, retval] long *nColumns
3499 );
3500
3501 /** @brief Returns a list of row indexes currently selected (0 based).
3502 @param [out] selectedRows
3503 An array of row indexes of selected rows (each index is 0 based), allocated
3504 by the server. Free it with CoTaskMemFree.
3505 @param [out] nRows
3506 The number of row indexes returned; the size of the returned array.
3507 @retval S_OK
3508 @retval S_FALSE if there are none, [out] values are NULL and 0 respectively
3509 */
3510 [propget] HRESULT selectedRows
3511 (
3512 [out, size_is(,*nRows)] long **selectedRows,
3513 [out, retval] long *nRows
3514 );
3515
3516 /** @brief Returns the summary description of the table. The returned object could be
3517 an IAccessible or an IAccessible2.
3518 @param [out] accessible
3519 Returns a reference to an implementation dependent accessible object
3520 representing the table's summary or a NULL pointer if the table
3521 does not support a summary.
3522 @retval S_OK
3523 @retval S_FALSE if there is nothing to return, [out] value is NULL
3524 */
3525 [propget] HRESULT summary
3526 (
3527 [out, retval] IUnknown **accessible
3528 );
3529
3530 /** @brief Returns a boolean value indicating whether the specified column is
3531 completely selected.
3532 @param [in] column
3533 0 based index of the column for which to determine whether it is selected.
3534 @param [out] isSelected
3535 Returns TRUE if the specified column is selected completely and FALSE otherw ise.
3536 @retval S_OK
3537 @retval E_INVALIDARG if bad [in] passed, [out] value is FALSE
3538 */
3539 [propget] HRESULT isColumnSelected
3540 (
3541 [in] long column,
3542 [out, retval] boolean *isSelected
3543 );
3544
3545 /** @brief Returns a boolean value indicating whether the specified row is com pletely
3546 selected.
3547 @param [in] row
3548 0 based index of the row for which to determine whether it is selected.
3549 @param [out] isSelected
3550 Returns TRUE if the specified row is selected completely and FALSE otherwise .
3551 @retval S_OK
3552 @retval E_INVALIDARG if bad [in] passed, [out] value is FALSE
3553 */
3554 [propget] HRESULT isRowSelected
3555 (
3556 [in] long row,
3557 [out, retval] boolean *isSelected
3558 );
3559
3560 /** @brief Selects a row and unselects all previously selected rows.
3561
3562 The behavior should mimic that of the application, but for those applications
3563 which do not have a means in the GUI to select a full row of cells the behav ior
3564 should be as follows: First any selected rows in the table are unselected. Then
3565 the entire row of cells for the specified row is selected. If any of the
3566 cells in the selected row span additional rows, the cells in those rows
3567 are also selected.
3568 @param [in] row
3569 0 based index of the row to be selected.
3570 @retval S_OK
3571 @retval E_INVALIDARG if bad [in] passed
3572 */
3573 HRESULT selectRow
3574 (
3575 [in] long row
3576 );
3577
3578 /** @brief Selects a column and unselects all previously selected columns.
3579
3580 The behavior should mimic that of the application, but for those applications
3581 which do not have a means in the GUI to select a full column of cells the be havior
3582 should be as follows: First any selected columns in the table are unselecte d. Then
3583 the entire column of cells for the specified column is selected. If any of the
3584 cells in the selected column span additional columns, the cells in those col umns
3585 are also selected.
3586 @param [in] column
3587 0 based index of the column to be selected.
3588 @retval S_OK
3589 @retval E_INVALIDARG if bad [in] passed
3590 */
3591 HRESULT selectColumn
3592 (
3593 [in] long column
3594 );
3595
3596 /** @brief Unselects one row, leaving other selected rows selected (if any).
3597
3598 The behavior should mimic that of the application, but for those applications
3599 which do not have a means in the GUI to unselect a full row of cells the
3600 behavior should be as follows: The entire row of cells for the specified
3601 row is unselected. If any of the cells in the selected row span additional
3602 rows, the cells in those rows are also unselected.
3603 @param [in] row
3604 0 based index of the row to be unselected.
3605 @retval S_OK
3606 @retval E_INVALIDARG if bad [in] passed
3607 */
3608 HRESULT unselectRow
3609 (
3610 [in] long row
3611 );
3612
3613 /** @brief Unselects one column, leaving other selected columns selected (if a ny).
3614
3615 The behavior should mimic that of the application, but for those applications
3616 which do not have a means in the GUI to unselect a full column of cells the
3617 behavior should be as follows: The entire column of cells for the specified
3618 column is unselected. If any of the cells in the selected column span addit ional
3619 columns, the cells in those columns are also unselected.
3620 @param [in] column
3621 0 based index of the column to be unselected.
3622 @retval S_OK
3623 @retval E_INVALIDARG if bad [in] passed
3624 */
3625 HRESULT unselectColumn
3626 (
3627 [in] long column
3628 );
3629
3630 /** @brief Returns the type and extents describing how a table changed.
3631
3632 Provided for use by the IA2_EVENT_TABLE_MODEL_CHANGED event handler.
3633
3634 This data is only guaranteed to be valid while the thread notifying the event
3635 continues. Once the handler has returned, the validity of the data depends on
3636 how the server manages the life cycle of its objects. Also, note that the ser ver
3637 may have different life cycle management strategies for controls depending on
3638 whether or not a control manages its children. Lists, trees, and tables can h ave
3639 a large number of children and thus it's possible that the child objects for those
3640 controls would only be created as needed. Servers should document their life cycle
3641 strategy as this will be of interest to assistive technology or script engine s
3642 accessing data out of process or from other threads. Servers only need to sav e the
3643 most recent row and column values associated with the change and a scope of t he
3644 entire application is adequate.
3645
3646 @param [out] modelChange
3647 A struct of (type(insert, delete, update), firstRow, lastRow, firstColumn, l astColumn).
3648 @retval S_OK
3649 @retval S_FALSE if there is nothing to return, [out] value is NULL
3650 */
3651 [propget] HRESULT modelChange
3652 (
3653 [out, retval] IA2TableModelChange *modelChange
3654 );
3655
3656 }
3657 /*************************************************************************
3658 *
3659 * File Name (AccessibleTableCell.idl)
3660 *
3661 * IAccessible2 IDL Specification
3662 *
3663 * Copyright (c) Linux Foundation 2007, 2009
3664 * Copyright (c) IBM Corp. 2006
3665 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
3666 *
3667 * This library is free software; you can redistribute it and/or
3668 * modify it under the terms of the GNU Lesser General Public
3669 * License version 2.1, as published by the Free Software Foundation; either
3670 * version 2.1 of the License, or (at your option) any later version.
3671 *
3672 * This library is distributed in the hope that it will be useful,
3673 * but WITHOUT ANY WARRANTY; without even the implied warranty of
3674 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
3675 * Lesser General Public License for more details.
3676 *
3677 * You should have received a copy of the GNU Lesser General Public
3678 * License along with this library; if not, write to the Free Software
3679 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 U SA
3680 *
3681 ************************************************************************/
3682
3683 import "objidl.idl";
3684 import "oaidl.idl";
3685 import "oleacc.idl";
3686
3687
3688 /** @brief This interface gives access to the cells of a two-dimensional table.
3689
3690 Please also refer to the IAccessibleTable2 interface.
3691
3692 */
3693 [object, uuid(594116B1-C99F-4847-AD06-0A7A86ECE645)]
3694 interface IAccessibleTableCell : IUnknown
3695 {
3696
3697 /** @brief Returns the number of columns occupied by this cell accessible.
3698
3699 The result is greater than 1 if the specified cell spans multiple columns.
3700 @param [out] nColumnsSpanned
3701 Returns the 1 based column extent of the specified cell.
3702 @retval S_OK
3703 */
3704 [propget] HRESULT columnExtent
3705 (
3706 [out, retval] long *nColumnsSpanned
3707 );
3708
3709 /** @brief Returns the column headers as an array of cell accessibles.
3710
3711 @param [out] cellAccessibles
3712 Pointer to an array of references to cell accessibles. The array is allocat ed
3713 by the server. Free it with CoTaskMemFree.
3714 @param [out] nColumnHeaderCells
3715 The number of accessibles returned; the size of the returned array.
3716 @retval S_OK
3717 @retval S_FALSE if there is no header, [out] values are NULL and 0 respective ly
3718 */
3719 [propget] HRESULT columnHeaderCells
3720 (
3721 [out, size_is(,*nColumnHeaderCells,)] IUnknown ***cellAccessibles,
3722 [out, retval] long *nColumnHeaderCells
3723 );
3724
3725 /** @brief Translates this cell accessible into the corresponding column index .
3726
3727 @param [out] columnIndex
3728 Returns the 0 based column index of the cell of the specified cell or the in dex of
3729 the first column if the cell spans multiple columns.
3730 @retval S_OK
3731 */
3732 [propget] HRESULT columnIndex
3733 (
3734 [out, retval] long *columnIndex
3735 );
3736
3737 /** @brief Returns the number of rows occupied by this cell accessible.
3738
3739 @param [out] nRowsSpanned
3740 Returns the row extent of the specified cell.
3741 @retval S_OK
3742 */
3743 [propget] HRESULT rowExtent
3744 (
3745 [out, retval] long *nRowsSpanned
3746 );
3747
3748 /** @brief Returns the row headers as an array of cell accessibles.
3749
3750 @param [out] cellAccessibles
3751 Pointer to an array of references to cell accessibles. The array is allocat ed
3752 by the server. Free it with CoTaskMemFree.
3753 @param [out] nRowHeaderCells
3754 The number of accessibles returned; the size of the returned array.
3755 @retval S_OK
3756 @retval S_FALSE if there is no header, [out] values are NULL and 0 respective ly
3757 */
3758 [propget] HRESULT rowHeaderCells
3759 (
3760 [out, size_is(,*nRowHeaderCells,)] IUnknown ***cellAccessibles,
3761 [out, retval] long *nRowHeaderCells
3762 );
3763
3764 /** @brief Translates this cell accessible into the corresponding row index.
3765
3766 @param [out] rowIndex
3767 Returns the 0 based row index of the specified cell or the index of
3768 the first row if the cell spans multiple rows.
3769 @retval S_OK
3770 */
3771 [propget] HRESULT rowIndex
3772 (
3773 [out, retval] long *rowIndex
3774 );
3775
3776 /** @brief Returns a boolean value indicating whether this cell is selected.
3777
3778 @param [out] isSelected
3779 Returns TRUE if the specified cell is selected and FALSE otherwise.
3780 @retval S_OK
3781 */
3782 [propget] HRESULT isSelected
3783 (
3784 [out, retval] boolean *isSelected
3785 );
3786
3787 /** @brief Gets the row and column indexes and extents of this cell accessible
3788 and whether or not it is selected.
3789
3790 This is a convenience function. It is not mandatory to implement it.
3791 @param [out] row
3792 0 based row index.
3793 @param [out] column
3794 0 based column index.
3795 @param [out] rowExtents
3796 Number of cells spanned by this cell in this row.
3797 @param [out] columnExtents
3798 Number of cells spanned by this cell in this column.
3799 @param [out] isSelected
3800 Indicates if the specified cell is selected.
3801 @retval S_OK
3802 */
3803 [propget] HRESULT rowColumnExtents
3804 (
3805 [out] long *row,
3806 [out] long *column,
3807 [out] long *rowExtents,
3808 [out] long *columnExtents,
3809 [out, retval] boolean *isSelected
3810 );
3811
3812 /** @brief Returns a reference to the accessbile of the containing table.
3813
3814 @param [out] table
3815 Returns a reference to the IUnknown of the containing table.
3816 @retval S_OK
3817 */
3818 [propget] HRESULT table
3819 (
3820 [out, retval] IUnknown **table
3821 );
3822
3823 }
3824 /*************************************************************************
3825 *
3826 * File Name (AccessibleImage)
3827 *
3828 * IAccessible2 IDL Specification
3829 *
3830 * Copyright (c) Linux Foundation 2007, 2008
3831 * Copyright (c) IBM Corp. 2006
3832 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
3833 *
3834 * This library is free software; you can redistribute it and/or
3835 * modify it under the terms of the GNU Lesser General Public
3836 * License version 2.1, as published by the Free Software Foundation; either
3837 * version 2.1 of the License, or (at your option) any later version.
3838 *
3839 * This library is distributed in the hope that it will be useful,
3840 * but WITHOUT ANY WARRANTY; without even the implied warranty of
3841 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
3842 * Lesser General Public License for more details.
3843 *
3844 * You should have received a copy of the GNU Lesser General Public
3845 * License along with this library; if not, write to the Free Software
3846 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02110-1301 USA
3847 *
3848 ************************************************************************/
3849
3850 import "objidl.idl";
3851 import "oaidl.idl";
3852 import "oleacc.idl";
3853
3854
3855 /** @brief This interface represents images and icons.
3856
3857 This interface is used for a representation of images like icons on buttons.
3858 %IAccessibleImage only needs to be implemented in certain situations. Some
3859 examples are:
3860 <ol>
3861 <li>The accessible name and description are not enough to fully
3862 describe the image, e.g. when the accessible description is used to define t he
3863 behavior of an actionable image and the image itself conveys semantically
3864 significant information.
3865 <li>The user can edit the content that includes an
3866 image and therefore the user needs to be able to review the image's position .
3867 </ol>
3868 */
3869 [object, uuid(FE5ABB3D-615E-4f7b-909F-5F0EDA9E8DDE)]
3870 interface IAccessibleImage : IUnknown
3871 {
3872 /** @brief Returns the localized description of the image.
3873 @param [out] description
3874 @retval S_OK
3875 @retval S_FALSE if there is nothing to return, [out] value is NULL
3876 */
3877 [propget] HRESULT description
3878 (
3879 [out, retval] BSTR *description
3880 );
3881
3882 /** @brief Returns the coordinates of the image.
3883 @param [in] coordinateType
3884 Specifies whether the returned coordinates should be relative to the screen or the parent object.
3885 @param [out] x
3886 @param [out] y
3887 @retval S_OK
3888 */
3889 [propget] HRESULT imagePosition
3890 (
3891 [in] enum IA2CoordinateType coordinateType,
3892 [out] long *x,
3893 [out, retval] long *y
3894 );
3895
3896 /** @brief Returns the size of the image in units specified by parent's coordi nate system.
3897 @param [out] height
3898 @param [out] width
3899 @retval S_OK
3900 */
3901
3902 [propget] HRESULT imageSize
3903 (
3904 [out] long *height,
3905 [out, retval] long *width
3906 );
3907 }
3908 /*************************************************************************
3909 *
3910 * File Name (AccessibleEventID.idl)
3911 *
3912 * IAccessible2 IDL Specification
3913 *
3914 * Copyright (c) Linux Foundation 2007, 2008
3915 * Copyright (c) IBM Corp. 2006
3916 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
3917 *
3918 * This library is free software; you can redistribute it and/or
3919 * modify it under the terms of the GNU Lesser General Public
3920 * License version 2.1, as published by the Free Software Foundation; either
3921 * version 2.1 of the License, or (at your option) any later version.
3922 *
3923 * This library is distributed in the hope that it will be useful,
3924 * but WITHOUT ANY WARRANTY; without even the implied warranty of
3925 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
3926 * Lesser General Public License for more details.
3927 *
3928 * You should have received a copy of the GNU Lesser General Public
3929 * License along with this library; if not, write to the Free Software
3930 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02110-1301 USA
3931 *
3932 ************************************************************************/
3933
3934 /** %IAccessible2 specific event constants
3935
3936 This enum defines the event IDs fired by %IAccessible2 objects. The event IDs
3937 are in addition to those used by MSAA.
3938 */
3939 enum IA2EventID {
3940
3941 /** The change of the number or attributes of actions of an accessible
3942 object is signaled by events of this type.
3943 */
3944 IA2_EVENT_ACTION_CHANGED = 0x101,
3945
3946 /** The active descendant of a component has changed.
3947
3948 Note: This event constant is misspelled and thus is deprecated and will be
3949 removed in a later version. Please use the correctly spelled version whi ch
3950 follows.
3951 */
3952 IA2_EVENT_ACTIVE_DECENDENT_CHANGED,
3953
3954 /** The active descendant of a component has changed. The active descendant
3955 is used in objects with transient children.
3956
3957 Note: Due to the fact that MSAA's WinEvents don't allow the active child ind ex
3958 to be passed on the IA2_EVENT_ACTIVE_DESCENDANT_CHANGED event the manage s
3959 descendants scheme can't be used. Instead the active child object h as to fire
3960 MSAA's EVENT_OBJECT_FOCUS. In a future release a new event mechanism ma y be
3961 added to provide for event specific data to be passed with the event. A t that
3962 time the IA2_EVENT_ACTIVE_DECENDENT_CHANGED event and
3963 IA2_STATE_MANAGES_DESCENDANTS state would be useful.
3964 */
3965 IA2_EVENT_ACTIVE_DESCENDANT_CHANGED = IA2_EVENT_ACTIVE_DECENDENT_CHANGED,
3966
3967 /** The document wide attributes of the document object have changed.
3968 */
3969 IA2_EVENT_DOCUMENT_ATTRIBUTE_CHANGED,
3970
3971 /** The contents of the document have changed.
3972 */
3973 IA2_EVENT_DOCUMENT_CONTENT_CHANGED,
3974
3975 /** The loading of the document has completed.
3976 */
3977 IA2_EVENT_DOCUMENT_LOAD_COMPLETE,
3978
3979 /** The loading of the document was interrupted.
3980 */
3981 IA2_EVENT_DOCUMENT_LOAD_STOPPED,
3982
3983 /** The document contents are being reloaded.
3984 */
3985 IA2_EVENT_DOCUMENT_RELOAD,
3986
3987 /** The ending index of this link within the containing string has changed.
3988 */
3989 IA2_EVENT_HYPERLINK_END_INDEX_CHANGED,
3990
3991 /** The number of anchors associated with this hyperlink object has changed.
3992 */
3993 IA2_EVENT_HYPERLINK_NUMBER_OF_ANCHORS_CHANGED,
3994
3995 /** The hyperlink selected state changed from selected to unselected or
3996 from unselected to selected.
3997 */
3998 IA2_EVENT_HYPERLINK_SELECTED_LINK_CHANGED,
3999
4000 /** One of the links associated with the hypertext object has been activated.
4001 */
4002 IA2_EVENT_HYPERTEXT_LINK_ACTIVATED,
4003
4004 /** One of the links associated with the hypertext object has been selected.
4005 */
4006 IA2_EVENT_HYPERTEXT_LINK_SELECTED,
4007
4008 /** The starting index of this link within the containing string has changed.
4009 */
4010 IA2_EVENT_HYPERLINK_START_INDEX_CHANGED,
4011
4012 /** Focus has changed from one hypertext object to another, or focus moved
4013 from a non-hypertext object to a hypertext object, or focus moved from a
4014 hypertext object to a non-hypertext object.
4015 */
4016 IA2_EVENT_HYPERTEXT_CHANGED,
4017
4018 /** The number of hyperlinks associated with a hypertext object changed
4019 */
4020 IA2_EVENT_HYPERTEXT_NLINKS_CHANGED,
4021
4022 /** An object's attributes changed.
4023 Also see ::IA2_EVENT_TEXT_ATTRIBUTE_CHANGED.
4024 */
4025 IA2_EVENT_OBJECT_ATTRIBUTE_CHANGED,
4026
4027 /** A slide changed in a presentation document or a page boundary was
4028 crossed in a word processing document.
4029 */
4030 IA2_EVENT_PAGE_CHANGED,
4031
4032 /** The caret moved from one section to the next.
4033 */
4034 IA2_EVENT_SECTION_CHANGED,
4035
4036 /** A table caption changed.
4037 */
4038 IA2_EVENT_TABLE_CAPTION_CHANGED,
4039
4040 /** A table's column description changed.
4041 */
4042 IA2_EVENT_TABLE_COLUMN_DESCRIPTION_CHANGED,
4043
4044 /** A table's column header changed.
4045 */
4046 IA2_EVENT_TABLE_COLUMN_HEADER_CHANGED,
4047
4048 /** A table's data changed.
4049 */
4050 IA2_EVENT_TABLE_MODEL_CHANGED,
4051
4052 /** A table's row description changed.
4053 */
4054 IA2_EVENT_TABLE_ROW_DESCRIPTION_CHANGED,
4055
4056 /** A table's row header changed.
4057 */
4058 IA2_EVENT_TABLE_ROW_HEADER_CHANGED,
4059
4060 /** A table's summary changed.
4061 */
4062 IA2_EVENT_TABLE_SUMMARY_CHANGED,
4063
4064 /** A text object's attributes changed.
4065 Also see ::IA2_EVENT_OBJECT_ATTRIBUTE_CHANGED.
4066 */
4067 IA2_EVENT_TEXT_ATTRIBUTE_CHANGED,
4068
4069 /** The caret has moved to a new position.
4070 */
4071 IA2_EVENT_TEXT_CARET_MOVED,
4072
4073 /** <b>Deprecated.</b> This event is equivalent to ::IA2_EVENT_TEXT_UPDATED.
4074 */
4075 IA2_EVENT_TEXT_CHANGED,
4076
4077 /** The caret moved from one column to the next.
4078 */
4079 IA2_EVENT_TEXT_COLUMN_CHANGED,
4080
4081 /** Text was inserted.
4082 */
4083 IA2_EVENT_TEXT_INSERTED,
4084
4085 /** Text was removed.
4086 */
4087 IA2_EVENT_TEXT_REMOVED,
4088
4089 /** This event indicates general text changes, i.e. changes to text that are
4090 exposed through the IAccessibleText interface. For compatibility with ATK/A T-SPI
4091 which does not have an equivalent event, servers can alternatively fire
4092 ::IA2_EVENT_TEXT_REMOVED and ::IA2_EVENT_TEXT_INSERTED.
4093 */
4094 IA2_EVENT_TEXT_UPDATED,
4095
4096 /** The text selection changed. Later versions of Microsoft development envir onments
4097 have an equivalent event identified, EVENT_OBJECT_TEXTSELECTIONCHANGED. Serv ers
4098 should use that if it is available and use IA2_EVENT_TEXT_SELECTION_CHANGED o therwise.
4099 Clients should be prepared to respond to either event.
4100
4101 */
4102 IA2_EVENT_TEXT_SELECTION_CHANGED,
4103
4104 /** A visible data event indicates the change of the visual appearance
4105 of an accessible object. This includes for example most of the
4106 attributes available via the IAccessibleComponent interface.
4107 */
4108 IA2_EVENT_VISIBLE_DATA_CHANGED
4109
4110 };
4111 /*************************************************************************
4112 *
4113 * File Name (AccessibleApplication.idl)
4114 *
4115 * IAccessible2 IDL Specification
4116 *
4117 * Copyright (c) Linux Foundation 2007, 2008
4118 * Copyright (c) IBM Corp. 2006
4119 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
4120 *
4121 * This library is free software; you can redistribute it and/or
4122 * modify it under the terms of the GNU Lesser General Public
4123 * License version 2.1, as published by the Free Software Foundation; either
4124 * version 2.1 of the License, or (at your option) any later version.
4125 *
4126 * This library is distributed in the hope that it will be useful,
4127 * but WITHOUT ANY WARRANTY; without even the implied warranty of
4128 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
4129 * Lesser General Public License for more details.
4130 *
4131 * You should have received a copy of the GNU Lesser General Public
4132 * License along with this library; if not, write to the Free Software
4133 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02110-1301 USA
4134 *
4135 ************************************************************************/
4136
4137 import "objidl.idl";
4138 import "oaidl.idl";
4139 import "oleacc.idl";
4140
4141 /** @brief This interface gives access to the application's name and version inf ormation.
4142
4143 This interface provides the AT with the information it needs to differentiate
4144 this application from other applications, from other versions of this
4145 application, or from other versions of this application running on different
4146 versions of an accessibility bridge or accessibility toolkit.
4147
4148 Servers implementing IAccessible2 should provide access to the %IAccessibleAppl ication
4149 interface via QueryService from any object so that ATs can easily determine spe cific
4150 information about the application such as its name or version.
4151 */
4152 [object, uuid(D49DED83-5B25-43F4-9B95-93B44595979E)]
4153 interface IAccessibleApplication : IUnknown
4154 {
4155
4156 /** @brief Returns the application name.
4157 @param [out] name
4158 @retval S_OK
4159 @retval S_FALSE if there is nothing to return, [out] value is NULL
4160 */
4161 [propget] HRESULT appName
4162 (
4163 [out, retval] BSTR *name
4164 );
4165
4166 /** @brief Returns the application version.
4167 @param [out] version
4168 @retval S_OK
4169 @retval S_FALSE if there is nothing to return, [out] value is NULL
4170 */
4171 [propget] HRESULT appVersion
4172 (
4173 [out, retval] BSTR *version
4174 );
4175
4176 /** @brief Returns the toolkit/bridge name.
4177 @param [out] name
4178 @retval S_OK
4179 @retval S_FALSE if there is nothing to return, [out] value is NULL
4180 */
4181 [propget] HRESULT toolkitName
4182 (
4183 [out, retval] BSTR *name
4184 );
4185
4186 /** @brief Returns the toolkit/bridge version.
4187 @param [out] version
4188 @retval S_OK
4189 @retval S_FALSE if there is nothing to return, [out] value is NULL
4190 */
4191 [propget] HRESULT toolkitVersion
4192 (
4193 [out, retval] BSTR *version
4194 );
4195
4196 }
4197
4198 /*************************************************************************
4199 *
4200 * File Name (IA2TypeLibrary.idl)
4201 *
4202 * IAccessible2 IDL Specification
4203 *
4204 * Copyright (c) Linux Foundation 2007, 2009
4205 * Copyright (c) IBM Corp. 2006
4206 * Copyright (c) Sun Microsystems, Inc. 2000, 2006
4207 *
4208 * This library is free software; you can redistribute it and/or
4209 * modify it under the terms of the GNU Lesser General Public
4210 * License version 2.1, as published by the Free Software Foundation; either
4211 * version 2.1 of the License, or (at your option) any later version.
4212 *
4213 * This library is distributed in the hope that it will be useful,
4214 * but WITHOUT ANY WARRANTY; without even the implied warranty of
4215 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
4216 * Lesser General Public License for more details.
4217 *
4218 * You should have received a copy of the GNU Lesser General Public
4219 * License along with this library; if not, write to the Free Software
4220 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02110-1301 USA
4221 *
4222 ************************************************************************/
4223
4224 // This is not a standalone file. It is to be appended to the end of the
4225 // merged IDL file.
4226
4227 cpp_quote("")
4228 cpp_quote("// Type Library Definitions")
4229 cpp_quote("")
4230
4231 [
4232 uuid(c974e070-3787-490a-87b0-e333b06ca1e2),
4233 helpstring("IAccessible2 Type Library"),
4234 version(1.1),
4235 hidden
4236 ]
4237
4238 library IAccessible2Lib
4239 {
4240 importlib ("stdole2.tlb");
4241 interface IAccessible2;
4242 interface IAccessibleAction;
4243 interface IAccessibleApplication;
4244 interface IAccessibleComponent;
4245 interface IAccessibleEditableText;
4246 interface IAccessibleHyperlink;
4247 interface IAccessibleHypertext;
4248 interface IAccessibleImage;
4249 interface IAccessibleRelation;
4250 interface IAccessibleTable;
4251 interface IAccessibleTable2;
4252 interface IAccessibleTableCell;
4253 interface IAccessibleText;
4254 interface IAccessibleValue;
4255 enum IA2CoordinateType;
4256 enum IA2EventID;
4257 enum IA2Role;
4258 enum IA2ScrollType;
4259 enum IA2States;
4260 enum IA2TableModelChangeType;
4261 enum IA2TextBoundaryType;
4262 enum IA2TextSpecialOffsets;
4263 }
OLDNEW
« no previous file with comments | « chrome/renderer/render_view.cc ('k') | third_party/iaccessible2/iaccessible2.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698