michael@0: /************************************************************************* michael@0: * michael@0: * File Name (IA2CommonTypes.idl) michael@0: * michael@0: * IAccessible2 IDL Specification michael@0: * michael@0: * Copyright (c) 2007, 2010 Linux Foundation michael@0: * Copyright (c) 2006 IBM Corporation michael@0: * Copyright (c) 2000, 2006 Sun Microsystems, Inc. michael@0: * All rights reserved. michael@0: * michael@0: * michael@0: * Redistribution and use in source and binary forms, with or without michael@0: * modification, are permitted provided that the following conditions michael@0: * are met: michael@0: * michael@0: * 1. Redistributions of source code must retain the above copyright michael@0: * notice, this list of conditions and the following disclaimer. michael@0: * michael@0: * 2. Redistributions in binary form must reproduce the above michael@0: * copyright notice, this list of conditions and the following michael@0: * disclaimer in the documentation and/or other materials michael@0: * provided with the distribution. michael@0: * michael@0: * 3. Neither the name of the Linux Foundation nor the names of its michael@0: * contributors may be used to endorse or promote products michael@0: * derived from this software without specific prior written michael@0: * permission. michael@0: * michael@0: * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND michael@0: * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, michael@0: * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF michael@0: * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE michael@0: * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR michael@0: * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, michael@0: * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT michael@0: * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; michael@0: * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) michael@0: * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN michael@0: * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR michael@0: * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, michael@0: * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. michael@0: * michael@0: * This BSD License conforms to the Open Source Initiative "Simplified michael@0: * BSD License" as published at: michael@0: * http://www.opensource.org/licenses/bsd-license.php michael@0: * michael@0: * IAccessible2 is a trademark of the Linux Foundation. The IAccessible2 michael@0: * mark may be used in accordance with the Linux Foundation Trademark michael@0: * Policy to indicate compliance with the IAccessible2 specification. michael@0: * michael@0: ************************************************************************/ michael@0: michael@0: /** These constants control the scrolling of an object or substring into a window. michael@0: michael@0: This enum is used in IAccessible2::scrollTo and IAccessibleText::scrollSubstringTo. michael@0: */ michael@0: enum IA2ScrollType { michael@0: michael@0: /** Scroll the top left corner of the object or substring such that the top left michael@0: corner (and as much as possible of the rest of the object or substring) is within michael@0: the top level window. In cases where the entire object or substring fits within michael@0: the top level window, the placement of the object or substring is dependent on michael@0: the application. For example, the object or substring may be scrolled to the michael@0: closest edge, the furthest edge, or midway between those two edges. In cases michael@0: where there is a hierarchy of nested scrollable controls, more than one control michael@0: may have to be scrolled. michael@0: */ michael@0: IA2_SCROLL_TYPE_TOP_LEFT, michael@0: michael@0: /** Scroll the bottom right corner of the object or substring such that the bottom right michael@0: corner (and as much as possible of the rest of the object or substring) is within michael@0: the top level window. In cases where the entire object or substring fits within michael@0: the top level window, the placement of the object or substring is dependent on michael@0: the application. For example, the object or substring may be scrolled to the michael@0: closest edge, the furthest edge, or midway between those two edges. In cases michael@0: where there is a hierarchy of nested scrollable controls, more than one control michael@0: may have to be scrolled. michael@0: */ michael@0: IA2_SCROLL_TYPE_BOTTOM_RIGHT, michael@0: michael@0: /** Scroll the top edge of the object or substring such that the top edge michael@0: (and as much as possible of the rest of the object or substring) is within the michael@0: top level window. In cases where the entire object or substring fits within michael@0: the top level window, the placement of the object or substring is dependent on michael@0: the application. For example, the object or substring may be scrolled to the michael@0: closest edge, the furthest edge, or midway between those two edges. In cases michael@0: where there is a hierarchy of nested scrollable controls, more than one control michael@0: may have to be scrolled. michael@0: */ michael@0: IA2_SCROLL_TYPE_TOP_EDGE, michael@0: michael@0: /** Scroll the bottom edge of the object or substring such that the bottom edge michael@0: (and as much as possible of the rest of the object or substring) is within the michael@0: top level window. In cases where the entire object or substring fits within michael@0: the top level window, the placement of the object or substring is dependent on michael@0: the application. For example, the object or substring may be scrolled to the michael@0: closest edge, the furthest edge, or midway between those two edges. In cases michael@0: where there is a hierarchy of nested scrollable controls, more than one control michael@0: may have to be scrolled. michael@0: */ michael@0: IA2_SCROLL_TYPE_BOTTOM_EDGE, michael@0: michael@0: /** Scroll the left edge of the object or substring such that the left edge michael@0: (and as much as possible of the rest of the object or substring) is within the michael@0: top level window. In cases where the entire object or substring fits within michael@0: the top level window, the placement of the object or substring is dependent on michael@0: the application. For example, the object or substring may be scrolled to the michael@0: closest edge, the furthest edge, or midway between those two edges. In cases michael@0: where there is a hierarchy of nested scrollable controls, more than one control michael@0: may have to be scrolled. michael@0: */ michael@0: IA2_SCROLL_TYPE_LEFT_EDGE, michael@0: michael@0: /** Scroll the right edge of the object or substring such that the right edge michael@0: (and as much as possible of the rest of the object or substring) is within the michael@0: top level window. In cases where the entire object or substring fits within michael@0: the top level window, the placement of the object or substring is dependent on michael@0: the application. For example, the object or substring may be scrolled to the michael@0: closest edge, the furthest edge, or midway between those two edges. In cases michael@0: where there is a hierarchy of nested scrollable controls, more than one control michael@0: may have to be scrolled. michael@0: */ michael@0: IA2_SCROLL_TYPE_RIGHT_EDGE, michael@0: michael@0: /** Scroll the object or substring such that as much as possible of the michael@0: object or substring is within the top level window. The placement of michael@0: the object is dependent on the application. For example, the object or michael@0: substring may be scrolled to to closest edge, the furthest edge, or midway michael@0: between those two edges. michael@0: */ michael@0: IA2_SCROLL_TYPE_ANYWHERE michael@0: }; michael@0: michael@0: /** These constants define which coordinate system a point is located in. michael@0: michael@0: This enum is used in IAccessible2::scrollToPoint, IAccessibleImage::imagePosition, michael@0: IAccessibleText::characterExtents, and IAccessibleText::offsetAtPoint, and michael@0: IAccessibleText::scrollSubstringToPoint. michael@0: */ michael@0: enum IA2CoordinateType { michael@0: michael@0: /// The coordinates are relative to the screen. michael@0: IA2_COORDTYPE_SCREEN_RELATIVE, michael@0: michael@0: /** The coordinates are relative to the upper left corner of the bounding box michael@0: of the immediate parent. michael@0: */ michael@0: IA2_COORDTYPE_PARENT_RELATIVE michael@0: michael@0: }; michael@0: michael@0: /** Special offsets for use in IAccessibleText and IAccessibleEditableText methods michael@0: michael@0: Refer to @ref _specialOffsets michael@0: "Special Offsets for use in the IAccessibleText and IAccessibleEditableText Methods" michael@0: for more information. michael@0: */ michael@0: enum IA2TextSpecialOffsets { michael@0: IA2_TEXT_OFFSET_LENGTH = -1, /**< This offset is equivalent to the length of the string. It eliminates michael@0: the need to call IAccessibleText::nCharacters. */ michael@0: IA2_TEXT_OFFSET_CARET = -2 /**< This offset signifies that the text related to the physical location michael@0: of the caret should be used. */ michael@0: }; michael@0: michael@0: /** These constants specify the kind of change made to a table. michael@0: michael@0: This enum is used in the IA2TableModelChange struct which in turn is used by michael@0: IAccessibleTable::modelChange and IAccessibleTable2::modelChange. michael@0: */ michael@0: enum IA2TableModelChangeType { michael@0: IA2_TABLE_MODEL_CHANGE_INSERT, // = 0; michael@0: IA2_TABLE_MODEL_CHANGE_DELETE, michael@0: IA2_TABLE_MODEL_CHANGE_UPDATE michael@0: }; michael@0: michael@0: /** A structure defining the type of and extents of changes made to a table michael@0: michael@0: IAccessibleTable::modelChange and IAccessibleTable2::modelChange return this struct. michael@0: In the case of an insertion or change the row and column offsets define the boundaries michael@0: of the inserted or changed subtable after the operation. In the case of a deletion michael@0: the row and column offsets define the boundaries of the subtable being removed before michael@0: the removal. michael@0: */ michael@0: typedef struct IA2TableModelChange { michael@0: enum IA2TableModelChangeType type; // insert, delete, update michael@0: long firstRow; ///< 0 based, inclusive michael@0: long lastRow; ///< 0 based, inclusive michael@0: long firstColumn; ///< 0 based, inclusive michael@0: long lastColumn; ///< 0 based, inclusive michael@0: } IA2TableModelChange;