IUIAutomationTextRange class com
Provides access to a span of continuous text in a container that supports the IUIAutomationTextPattern interface.
Client applications can use the IUIAutomationTextRange interface to select, compare, and retrieve embedded objects from the text span.
To learn more, see learn.microsoft.com/windows/win32/api/uiautomationclient/nn-uiautomationclient-iuiautomationtextrange.
- Inheritance
- Implemented types
- Implementers
Constructors
- IUIAutomationTextRange(VTablePointer ptr)
- Creates a new instance of IUIAutomationTextRange from a VTablePointer.
- IUIAutomationTextRange.from(IUnknown interface)
-
Creates a new instance of IUIAutomationTextRange from an existing
interface.factory
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- ptr → VTablePointer
-
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
addRef(
) → int -
Increments the reference count of this COM object.
inherited
-
addToSelection(
) → void - Adds the text range to the collection of selected text ranges in a control that supports multiple, disjoint spans of selected text.
-
clone(
) → IUIAutomationTextRange? - Retrieves a new IUIAutomationTextRange identical to the original and inheriting all properties of the original.
-
compare(
IUIAutomationTextRange? range) → bool - Retrieves a value that specifies whether this text range has the same endpoints as another text range.
-
compareEndpoints(
TextPatternRangeEndpoint srcEndPoint, IUIAutomationTextRange? range, TextPatternRangeEndpoint targetEndPoint) → int - Retrieves a value that specifies whether the start or end endpoint of this text range is the same as the start or end endpoint of another text range.
-
expandToEnclosingUnit(
TextUnit textUnit) → void - Normalizes the text range by the specified text unit.
-
findAttribute(
UIA_TEXTATTRIBUTE_ID attr, VARIANT val, bool backward) → IUIAutomationTextRange? - Retrieves a text range subset that has the specified text attribute value.
-
findText(
BSTR text, bool backward, bool ignoreCase) → IUIAutomationTextRange? - Retrieves a text range subset that contains the specified text.
-
getAttributeValue(
UIA_TEXTATTRIBUTE_ID attr) → Pointer< VARIANT> - Retrieves the value of the specified text attribute across the entire text range.
-
getBoundingRectangles(
) → Pointer< SAFEARRAY> - Retrieves a collection of bounding rectangles for each fully or partially visible line of text in a text range.
-
getChildren(
) → IUIAutomationElementArray? - Retrieves a collection of all embedded objects that fall within the text range.
-
getEnclosingElement(
) → IUIAutomationElement? - Returns the innermost UI Automation element that encloses the text range.
-
getText(
int maxLength) → BSTR - Returns the plain text of the text range.
-
move(
TextUnit unit, int count) → int - Moves the text range forward or backward by the specified number of text units.
-
moveEndpointByRange(
TextPatternRangeEndpoint srcEndPoint, IUIAutomationTextRange? range, TextPatternRangeEndpoint targetEndPoint) → void - Moves one endpoint of the current text range to the specified endpoint of a second text range.
-
moveEndpointByUnit(
TextPatternRangeEndpoint endpoint, TextUnit unit, int count) → int - Moves one endpoint of the text range the specified number of text units within the document range.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
queryInterface<
T extends IUnknown> () → T -
Queries this COM object for a specific interface defined by the type
parameter
T.inherited -
release(
) → int -
Decrements the reference count of this COM object.
inherited
-
removeFromSelection(
) → void - Removes the text range from an existing collection of selected text in a text container that supports multiple, disjoint selections.
-
scrollIntoView(
bool alignToTop) → void - Causes the text control to scroll until the text range is visible in the viewport.
-
select(
) → void - Selects the span of text that corresponds to this text range, and removes any previous selection.
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited