Struct xpcom::interfaces::nsIAccessibleText
[−]
[src]
#[repr(C)]pub struct nsIAccessibleText { /* fields omitted */ }
interface nsIAccessibleText : nsISupports
Methods
impl nsIAccessibleText
[src]
pub fn coerce<T: nsIAccessibleTextCoerce>(&self) -> &T
[src]
Cast this nsIAccessibleText
to one of its base interfaces.
impl nsIAccessibleText
[src]
pub const TEXT_OFFSET_END_OF_TEXT: i64
TEXT_OFFSET_END_OF_TEXT: i64 = -1
pub const TEXT_OFFSET_CARET: i64
TEXT_OFFSET_CARET: i64 = -2
pub const BOUNDARY_CHAR: i64
BOUNDARY_CHAR: i64 = 0
pub const BOUNDARY_WORD_START: i64
BOUNDARY_WORD_START: i64 = 1
pub const BOUNDARY_WORD_END: i64
BOUNDARY_WORD_END: i64 = 2
pub const BOUNDARY_SENTENCE_START: i64
BOUNDARY_SENTENCE_START: i64 = 3
pub const BOUNDARY_SENTENCE_END: i64
BOUNDARY_SENTENCE_END: i64 = 4
pub const BOUNDARY_LINE_START: i64
BOUNDARY_LINE_START: i64 = 5
pub const BOUNDARY_LINE_END: i64
BOUNDARY_LINE_END: i64 = 6
pub unsafe fn GetCaretOffset(&self, aCaretOffset: *mut int32_t) -> nsresult
[src]
/**
* The current current caret offset.
* If set < 0 then caret will be placed at the end of the text
*/
attribute long caretOffset;
pub unsafe fn SetCaretOffset(&self, aCaretOffset: int32_t) -> nsresult
[src]
/**
* The current current caret offset.
* If set < 0 then caret will be placed at the end of the text
*/
attribute long caretOffset;
pub unsafe fn GetCharacterCount(
&self,
aCharacterCount: *mut int32_t
) -> nsresult
[src]
&self,
aCharacterCount: *mut int32_t
) -> nsresult
readonly attribute long characterCount;
pub unsafe fn GetSelectionCount(
&self,
aSelectionCount: *mut int32_t
) -> nsresult
[src]
&self,
aSelectionCount: *mut int32_t
) -> nsresult
readonly attribute long selectionCount;
pub unsafe fn GetText(
&self,
startOffset: int32_t,
endOffset: int32_t,
_retval: &mut nsAString
) -> nsresult
[src]
&self,
startOffset: int32_t,
endOffset: int32_t,
_retval: &mut nsAString
) -> nsresult
/**
* String methods may need to return multibyte-encoded strings,
* since some locales can't be encoded using 16-bit chars.
* So the methods below might return UTF-16 strings, or they could
* return "string" values which are UTF-8.
*/
AString getText (in long startOffset, in long endOffset);
pub unsafe fn GetTextAfterOffset(
&self,
offset: int32_t,
boundaryType: AccessibleTextBoundary,
startOffset: *mut int32_t,
endOffset: *mut int32_t,
_retval: &mut nsAString
) -> nsresult
[src]
&self,
offset: int32_t,
boundaryType: AccessibleTextBoundary,
startOffset: *mut int32_t,
endOffset: *mut int32_t,
_retval: &mut nsAString
) -> nsresult
AString getTextAfterOffset (in long offset, in AccessibleTextBoundary boundaryType, out long startOffset, out long endOffset);
pub unsafe fn GetTextAtOffset(
&self,
offset: int32_t,
boundaryType: AccessibleTextBoundary,
startOffset: *mut int32_t,
endOffset: *mut int32_t,
_retval: &mut nsAString
) -> nsresult
[src]
&self,
offset: int32_t,
boundaryType: AccessibleTextBoundary,
startOffset: *mut int32_t,
endOffset: *mut int32_t,
_retval: &mut nsAString
) -> nsresult
AString getTextAtOffset (in long offset, in AccessibleTextBoundary boundaryType, out long startOffset, out long endOffset);
pub unsafe fn GetTextBeforeOffset(
&self,
offset: int32_t,
boundaryType: AccessibleTextBoundary,
startOffset: *mut int32_t,
endOffset: *mut int32_t,
_retval: &mut nsAString
) -> nsresult
[src]
&self,
offset: int32_t,
boundaryType: AccessibleTextBoundary,
startOffset: *mut int32_t,
endOffset: *mut int32_t,
_retval: &mut nsAString
) -> nsresult
AString getTextBeforeOffset (in long offset, in AccessibleTextBoundary boundaryType, out long startOffset, out long endOffset);
pub unsafe fn GetCharacterAtOffset(
&self,
offset: int32_t,
_retval: *mut int16_t
) -> nsresult
[src]
&self,
offset: int32_t,
_retval: *mut int16_t
) -> nsresult
/**
* It would be better to return an unsigned long here,
* to allow unicode chars > 16 bits
*/
wchar getCharacterAtOffset (in long offset);
pub unsafe fn GetTextAttributes(
&self,
includeDefAttrs: bool,
offset: int32_t,
rangeStartOffset: *mut int32_t,
rangeEndOffset: *mut int32_t,
_retval: *mut *const nsIPersistentProperties
) -> nsresult
[src]
&self,
includeDefAttrs: bool,
offset: int32_t,
rangeStartOffset: *mut int32_t,
rangeEndOffset: *mut int32_t,
_retval: *mut *const nsIPersistentProperties
) -> nsresult
/**
* Get the accessible start/end offsets around the given offset,
* return the text attributes for this range of text.
*
* @param includeDefAttrs [in] points whether text attributes applied to
* the entire accessible should be included or not.
* @param offset [in] text offset
* @param rangeStartOffset [out] start offset of the range of text
* @param rangeEndOffset [out] end offset of the range of text
*/
nsIPersistentProperties getTextAttributes (in boolean includeDefAttrs, in long offset, out long rangeStartOffset, out long rangeEndOffset);
pub unsafe fn GetDefaultTextAttributes(
&self,
aDefaultTextAttributes: *mut *const nsIPersistentProperties
) -> nsresult
[src]
&self,
aDefaultTextAttributes: *mut *const nsIPersistentProperties
) -> nsresult
/**
* Return the text attributes that apply to the entire accessible.
*/
readonly attribute nsIPersistentProperties defaultTextAttributes;
pub unsafe fn GetCharacterExtents(
&self,
offset: int32_t,
x: *mut int32_t,
y: *mut int32_t,
width: *mut int32_t,
height: *mut int32_t,
coordType: uint32_t
) -> nsresult
[src]
&self,
offset: int32_t,
x: *mut int32_t,
y: *mut int32_t,
width: *mut int32_t,
height: *mut int32_t,
coordType: uint32_t
) -> nsresult
/**
* Returns the bounding box of the specified position.
*
* The virtual character after the last character of the represented text,
* i.e. the one at position length is a special case. It represents the
* current input position and will therefore typically be queried by AT more
* often than other positions. Because it does not represent an existing
* character its bounding box is defined in relation to preceding characters.
* It should be roughly equivalent to the bounding box of some character when
* inserted at the end of the text. Its height typically being the maximal
* height of all the characters in the text or the height of the preceding
* character, its width being at least one pixel so that the bounding box is
* not degenerate.
*
* @param offset - Index of the character for which to return its bounding
* box. The valid range is 0..length.
* @param x - X coordinate of the bounding box of the referenced character.
* @param y - Y coordinate of the bounding box of the referenced character.
* @param width - Width of the bounding box of the referenced character.
* @param height - Height of the bounding box of the referenced character.
* @param coordType - Specifies if the coordinates are relative to the screen
* or to the parent window (see constants declared in
* nsIAccessibleCoordinateType).
*/
void getCharacterExtents (in long offset, out long x, out long y, out long width, out long height, in unsigned long coordType);
pub unsafe fn GetRangeExtents(
&self,
startOffset: int32_t,
endOffset: int32_t,
x: *mut int32_t,
y: *mut int32_t,
width: *mut int32_t,
height: *mut int32_t,
coordType: uint32_t
) -> nsresult
[src]
&self,
startOffset: int32_t,
endOffset: int32_t,
x: *mut int32_t,
y: *mut int32_t,
width: *mut int32_t,
height: *mut int32_t,
coordType: uint32_t
) -> nsresult
void getRangeExtents (in long startOffset, in long endOffset, out long x, out long y, out long width, out long height, in unsigned long coordType);
pub unsafe fn GetOffsetAtPoint(
&self,
x: int32_t,
y: int32_t,
coordType: uint32_t,
_retval: *mut int32_t
) -> nsresult
[src]
&self,
x: int32_t,
y: int32_t,
coordType: uint32_t,
_retval: *mut int32_t
) -> nsresult
/**
* Get the text offset at the given point, or return -1
* if no character exists at that point
*
* @param x - The position's x value for which to look up the index of the
* character that is rendered on to the display at that point.
* @param y - The position's y value for which to look up the index of the
* character that is rendered on to the display at that point.
* @param coordType - Screen coordinates or window coordinates (see constants
* declared in nsIAccessibleCoordinateType).
* @return offset - Index of the character under the given point or -1 if
* the point is invalid or there is no character under
* the point.
*/
long getOffsetAtPoint (in long x, in long y, in unsigned long coordType);
pub unsafe fn GetSelectionBounds(
&self,
selectionNum: int32_t,
startOffset: *mut int32_t,
endOffset: *mut int32_t
) -> nsresult
[src]
&self,
selectionNum: int32_t,
startOffset: *mut int32_t,
endOffset: *mut int32_t
) -> nsresult
void getSelectionBounds (in long selectionNum, out long startOffset, out long endOffset);
pub unsafe fn SetSelectionBounds(
&self,
selectionNum: int32_t,
startOffset: int32_t,
endOffset: int32_t
) -> nsresult
[src]
&self,
selectionNum: int32_t,
startOffset: int32_t,
endOffset: int32_t
) -> nsresult
/**
* Set the bounds for the given selection range
*/
void setSelectionBounds (in long selectionNum, in long startOffset, in long endOffset);
pub unsafe fn AddSelection(
&self,
startOffset: int32_t,
endOffset: int32_t
) -> nsresult
[src]
&self,
startOffset: int32_t,
endOffset: int32_t
) -> nsresult
void addSelection (in long startOffset, in long endOffset);
pub unsafe fn RemoveSelection(&self, selectionNum: int32_t) -> nsresult
[src]
void removeSelection (in long selectionNum);
pub unsafe fn ScrollSubstringTo(
&self,
startIndex: int32_t,
endIndex: int32_t,
scrollType: uint32_t
) -> nsresult
[src]
&self,
startIndex: int32_t,
endIndex: int32_t,
scrollType: uint32_t
) -> nsresult
/**
* Makes a specific part of string visible on screen.
*
* @param startIndex 0-based character offset
* @param endIndex 0-based character offset - the offset of the
* character just past the last character of the
* string
* @param scrollType defines how to scroll (see nsIAccessibleScrollType for
* available constants)
*/
void scrollSubstringTo (in long startIndex, in long endIndex, in unsigned long scrollType);
pub unsafe fn ScrollSubstringToPoint(
&self,
startIndex: int32_t,
endIndex: int32_t,
coordinateType: uint32_t,
x: int32_t,
y: int32_t
) -> nsresult
[src]
&self,
startIndex: int32_t,
endIndex: int32_t,
coordinateType: uint32_t,
x: int32_t,
y: int32_t
) -> nsresult
/**
* Moves the top left of a substring to a specified location.
*
* @param startIndex 0-based character offset
* @param endIndex 0-based character offset - the offset of the
* character just past the last character of
* the string
* @param coordinateType specifies the coordinates origin (for available
* constants refer to nsIAccessibleCoordinateType)
* @param x defines the x coordinate
* @param y defines the y coordinate
*/
void scrollSubstringToPoint (in long startIndex, in long endIndex, in unsigned long coordinateType, in long x, in long y);
pub unsafe fn GetEnclosingRange(
&self,
aEnclosingRange: *mut *const nsIAccessibleTextRange
) -> nsresult
[src]
&self,
aEnclosingRange: *mut *const nsIAccessibleTextRange
) -> nsresult
/**
* Return a range that encloses this text control or otherwise the document
* this text accessible belongs to.
*/
readonly attribute nsIAccessibleTextRange enclosingRange;
pub unsafe fn GetSelectionRanges(
&self,
aSelectionRanges: *mut *const nsIArray
) -> nsresult
[src]
&self,
aSelectionRanges: *mut *const nsIArray
) -> nsresult
/**
* Return an array of disjoint ranges for selected text within the text control
* or otherwise the document this accessible belongs to.
*/
readonly attribute nsIArray selectionRanges;
pub unsafe fn GetVisibleRanges(
&self,
aVisibleRanges: *mut *const nsIArray
) -> nsresult
[src]
&self,
aVisibleRanges: *mut *const nsIArray
) -> nsresult
/**
* Return an array of disjoint ranges of visible text within the text control
* or otherwise the document this accessible belongs to.
*/
readonly attribute nsIArray visibleRanges;
pub unsafe fn GetRangeByChild(
&self,
child: *const nsIAccessible,
_retval: *mut *const nsIAccessibleTextRange
) -> nsresult
[src]
&self,
child: *const nsIAccessible,
_retval: *mut *const nsIAccessibleTextRange
) -> nsresult
/**
* Return a range containing the given accessible.
*/
nsIAccessibleTextRange getRangeByChild (in nsIAccessible child);
pub unsafe fn GetRangeAtPoint(
&self,
x: int32_t,
y: int32_t,
_retval: *mut *const nsIAccessibleTextRange
) -> nsresult
[src]
&self,
x: int32_t,
y: int32_t,
_retval: *mut *const nsIAccessibleTextRange
) -> nsresult
/**
* Return a range containing an accessible at the given point.
*/
nsIAccessibleTextRange getRangeAtPoint (in long x, in long y);
Methods from Deref<Target = nsISupports>
pub fn coerce<T: nsISupportsCoerce>(&self) -> &T
[src]
Cast this nsISupports
to one of its base interfaces.
pub unsafe fn QueryInterface(
&self,
uuid: &nsIID,
result: *mut *mut c_void
) -> nsresult
[src]
&self,
uuid: &nsIID,
result: *mut *mut c_void
) -> nsresult
void QueryInterface (in nsIIDRef uuid, [iid_is (uuid), retval] out nsQIResult result);
pub unsafe fn AddRef(&self) -> nsrefcnt
[src]
[noscript,notxpcom] nsrefcnt AddRef ();
pub unsafe fn Release(&self) -> nsrefcnt
[src]
[noscript,notxpcom] nsrefcnt Release ();
Trait Implementations
impl XpCom for nsIAccessibleText
[src]
const IID: nsIID
IID: nsIID = nsID(2477599905, 61739, 19129, [167, 147, 149, 217, 250, 157, 23, 116])
fn query_interface<T: XpCom>(&self) -> Option<RefPtr<T>>
[src]
Perform a QueryInterface call on this object, attempting to dynamically cast it to the requested interface type. Returns Some(RefPtr) if the cast succeeded, and None otherwise. Read more
impl RefCounted for nsIAccessibleText
[src]
unsafe fn addref(&self)
[src]
Increment the reference count.
unsafe fn release(&self)
[src]
Decrement the reference count, potentially freeing backing memory.
impl Deref for nsIAccessibleText
[src]
type Target = nsISupports
The resulting type after dereferencing.
fn deref(&self) -> &nsISupports
[src]
Dereferences the value.