Udostępnij za pośrednictwem


ITextRangeProvider2 Interface

Definition

Extends the ITextRange interface to enable Microsoft UI Automation providers to programmatically open context menus that are contextual to text input operations.

public interface class ITextRangeProvider2 : ITextRangeProvider
/// [Windows.Foundation.Metadata.ContractVersion(Microsoft.UI.Xaml.WinUIContract, 65536)]
/// [Windows.Foundation.Metadata.Guid(886351886, 14011, 21346, 165, 59, 73, 4, 40, 168, 179, 103)]
struct ITextRangeProvider2 : ITextRangeProvider
[Windows.Foundation.Metadata.ContractVersion(typeof(Microsoft.UI.Xaml.WinUIContract), 65536)]
[Windows.Foundation.Metadata.Guid(886351886, 14011, 21346, 165, 59, 73, 4, 40, 168, 179, 103)]
public interface ITextRangeProvider2 : ITextRangeProvider
Public Interface ITextRangeProvider2
Implements ITextRangeProvider
Attributes
Implements

Methods

AddToSelection()

Adds to the collection of highlighted text in a text container that supports multiple disjoint selections.

(Inherited from ITextRangeProvider)
Clone()

Returns a new ITextRangeProvider that is identical to the original ITextRangeProvider and that inherits all the properties of the original.

(Inherited from ITextRangeProvider)
Compare(ITextRangeProvider)

Returns a value that indicates whether the start and end points of a text range are the same as another text range.

(Inherited from ITextRangeProvider)
CompareEndpoints(TextPatternRangeEndpoint, ITextRangeProvider, TextPatternRangeEndpoint)

Returns a value that indicates whether two text ranges have identical endpoints.

(Inherited from ITextRangeProvider)
ExpandToEnclosingUnit(TextUnit)

Expands the text range to the specified text unit.

(Inherited from ITextRangeProvider)
FindAttribute(Int32, Object, Boolean)

Returns a text range subset that has the specified attribute ID and attribute value.

(Inherited from ITextRangeProvider)
FindText(String, Boolean, Boolean)

Returns a text range subset that contains the specified text.

(Inherited from ITextRangeProvider)
GetAttributeValue(Int32)

Retrieves the value of the specified attribute ID across the text range.

(Inherited from ITextRangeProvider)
GetBoundingRectangles(Double[])

Retrieves a collection of bounding rectangles for each fully or partially visible line of text in a text range.

(Inherited from ITextRangeProvider)
GetChildren()

Retrieves a collection of all the embedded objects that exist within the text range.

(Inherited from ITextRangeProvider)
GetEnclosingElement()

Returns the innermost element that encloses the text range.

(Inherited from ITextRangeProvider)
GetText(Int32)

Retrieves the plain text of the range.

(Inherited from ITextRangeProvider)
Move(TextUnit, Int32)

Moves the text range the specified number of text units.

(Inherited from ITextRangeProvider)
MoveEndpointByRange(TextPatternRangeEndpoint, ITextRangeProvider, TextPatternRangeEndpoint)

Moves one endpoint of a text range to the specified endpoint of a second text range.

(Inherited from ITextRangeProvider)
MoveEndpointByUnit(TextPatternRangeEndpoint, TextUnit, Int32)

Moves one endpoint of the text range the specified number of text units within the document range.

(Inherited from ITextRangeProvider)
RemoveFromSelection()

From the collection of highlighted text in a text container that supports multiple disjoint selections, removes a highlighted section of text that corresponds to the caller's text range endpoints.

(Inherited from ITextRangeProvider)
ScrollIntoView(Boolean)

Causes the text control to scroll vertically until the text range is visible in the viewport.

(Inherited from ITextRangeProvider)
Select()

Highlights text in the text control that corresponds to the start and end endpoints of the text range.

(Inherited from ITextRangeProvider)
ShowContextMenu()

Shows the available context menu for the owner element.

Applies to

See also