michael@0: /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: #include "nsISupports.idl" michael@0: michael@0: interface nsIAccessible; michael@0: interface nsIAccessiblePivot; michael@0: interface nsIDOMDocument; michael@0: interface nsIDOMNode; michael@0: interface nsIDOMWindow; michael@0: michael@0: /** michael@0: * An interface for in-process accessibility clients michael@0: * that wish to retrieve information about a document. michael@0: * When accessibility is turned on in Gecko, michael@0: * there is an nsIAccessibleDocument for each document michael@0: * whether it is XUL, HTML or whatever. michael@0: * You can QueryInterface to nsIAccessibleDocument from the nsIAccessible for michael@0: * the root node of a document. You can also get one from michael@0: * nsIAccessible::GetAccessibleDocument() or michael@0: * nsIAccessibleEvent::GetAccessibleDocument() michael@0: */ michael@0: [scriptable, uuid(fe5b3886-2b6a-491a-80cd-a3e6342c451d)] michael@0: interface nsIAccessibleDocument : nsISupports michael@0: { michael@0: /** michael@0: * The URL of the document michael@0: */ michael@0: readonly attribute AString URL; michael@0: michael@0: /** michael@0: * The title of the document, as specified in the document. michael@0: */ michael@0: readonly attribute AString title; michael@0: michael@0: /** michael@0: * The mime type of the document michael@0: */ michael@0: readonly attribute AString mimeType; michael@0: michael@0: /** michael@0: * The doc type of the document, as specified in the document. michael@0: */ michael@0: readonly attribute AString docType; michael@0: michael@0: /** michael@0: * The nsIDOMDocument interface associated with this document. michael@0: */ michael@0: readonly attribute nsIDOMDocument DOMDocument; michael@0: michael@0: /** michael@0: * The nsIDOMWindow that the document resides in. michael@0: */ michael@0: readonly attribute nsIDOMWindow window; michael@0: michael@0: /** michael@0: * The namespace for each ID that is handed back. michael@0: */ michael@0: AString getNameSpaceURIForID(in short nameSpaceID); michael@0: michael@0: /** michael@0: * The window handle for the OS window the document is being displayed in. michael@0: * For example, in Windows you can static cast it to an HWND. michael@0: */ michael@0: [noscript] readonly attribute voidPtr windowHandle; michael@0: michael@0: /** michael@0: * Return the parent document accessible. michael@0: */ michael@0: readonly attribute nsIAccessibleDocument parentDocument; michael@0: michael@0: /** michael@0: * Return the count of child document accessibles. michael@0: */ michael@0: readonly attribute unsigned long childDocumentCount; michael@0: michael@0: /** michael@0: * The virtual cursor pivot this document manages. michael@0: */ michael@0: readonly attribute nsIAccessiblePivot virtualCursor; michael@0: michael@0: /** michael@0: * Return the child document accessible at the given index. michael@0: */ michael@0: nsIAccessibleDocument getChildDocumentAt(in unsigned long index); michael@0: };