michael@0: /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- michael@0: * 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: [scriptable, uuid(93d0ba57-0d20-49d1-aede-8fde6699855d)] michael@0: interface nsIAccessibleEditableText : nsISupports michael@0: { michael@0: /** michael@0: * Replaces the text represented by this object by the given text. michael@0: */ michael@0: void setTextContents (in AString text); michael@0: michael@0: /** michael@0: * Inserts text at the specified position. michael@0: * michael@0: * @param text - text that is inserted. michael@0: * @param position - index at which to insert the text. michael@0: */ michael@0: [binaryname(ScriptableInsertText)] michael@0: void insertText(in AString text, in long position); michael@0: michael@0: /** michael@0: * Copies the text range into the clipboard. michael@0: * michael@0: * @param startPos - start index of the text to moved into the clipboard. michael@0: * @param endPos - end index of the text to moved into the clipboard. michael@0: */ michael@0: [binaryname(ScriptableCopyText)] michael@0: void copyText(in long startPos, in long endPos); michael@0: michael@0: /** michael@0: * Deletes a range of text and copies it to the clipboard. michael@0: * michael@0: * @param startPos - start index of the text to be deleted. michael@0: * @param endOffset - end index of the text to be deleted. michael@0: */ michael@0: [binaryname(ScriptableCutText)] michael@0: void cutText(in long startPos, in long endPos); michael@0: michael@0: /** michael@0: * Deletes a range of text. michael@0: * michael@0: * @param startPos - start index of the text to be deleted. michael@0: * @param endPos - end index of the text to be deleted. michael@0: */ michael@0: [binaryname(ScriptableDeleteText)] michael@0: void deleteText(in long startPos, in long endPos); michael@0: michael@0: /** michael@0: * Pastes text from the clipboard. michael@0: * michael@0: * @param position - index at which to insert the text from the system michael@0: * clipboard into the text represented by this object. michael@0: */ michael@0: [binaryname(ScriptablePasteText)] michael@0: void pasteText(in long position); michael@0: };