ITextRangeProvider
trait · ferroui-controls · v0.5.0
trait ITextRangeProvider
A live range of text exposed to accessibility. Range operations change the range object; only selection methods change the control's selection. Ranges follow edits and become unavailable when their host displays another document.
Members
as_anypeerclone_rangecomparecompare_endpointsexpand_to_enclosing_unitfind_attributefind_textget_attribute_valueget_bounding_rectanglesget_enclosing_elementget_textmove_bymove_endpoint_by_unitmove_endpoint_by_rangeselectadd_to_selectionremove_from_selectionscroll_into_viewget_children
as_any
fn as_any(self: &Self) -> &dyn Any
peer
fn peer(self: &Self) -> Result<Ref<AutomationPeer>, ProviderError>
The text-pattern owner, also used by platform bridges for screen transforms.
clone_range
fn clone_range(self: &Self) -> Result<Rc<dyn ITextRangeProvider>, ProviderError>
compare
fn compare(self: &Self, range: &dyn ITextRangeProvider) -> Result<bool, ProviderError>
compare_endpoints
fn compare_endpoints(self: &Self, endpoint: TextPatternRangeEndpoint, range: &dyn ITextRangeProvider, target_endpoint: TextPatternRangeEndpoint) -> Result<i32, ProviderError>
expand_to_enclosing_unit
fn expand_to_enclosing_unit(self: &Self, unit: TextUnit) -> Result<(), ProviderError>
find_attribute
fn find_attribute(self: &Self, attribute: TextAttribute, value: &TextAttributeValue, backwards: bool) -> Result<Option<Rc<dyn ITextRangeProvider>>, ProviderError>
find_text
fn find_text(self: &Self, text: &str, backwards: bool, ignore_case: bool) -> Result<Option<Rc<dyn ITextRangeProvider>>, ProviderError>
get_attribute_value
fn get_attribute_value(self: &Self, attribute: TextAttribute) -> Result<TextAttributeValue, ProviderError>
get_bounding_rectangles
fn get_bounding_rectangles(self: &Self) -> Result<Vec<Rect>, ProviderError>
get_enclosing_element
fn get_enclosing_element(self: &Self) -> Result<Ref<AutomationPeer>, ProviderError>
get_text
fn get_text(self: &Self, max_length: Option<usize>) -> Result<String, ProviderError>
None retrieves all text. A finite limit never splits a surrogate pair.
move_by
fn move_by(self: &Self, unit: TextUnit, count: i32) -> Result<i32, ProviderError>
move_endpoint_by_unit
fn move_endpoint_by_unit(self: &Self, endpoint: TextPatternRangeEndpoint, unit: TextUnit, count: i32) -> Result<i32, ProviderError>
move_endpoint_by_range
fn move_endpoint_by_range(self: &Self, endpoint: TextPatternRangeEndpoint, range: &dyn ITextRangeProvider, target_endpoint: TextPatternRangeEndpoint) -> Result<(), ProviderError>
select
fn select(self: &Self) -> Result<(), ProviderError>
add_to_selection
fn add_to_selection(self: &Self) -> Result<(), ProviderError>
remove_from_selection
fn remove_from_selection(self: &Self) -> Result<(), ProviderError>
scroll_into_view
fn scroll_into_view(self: &Self, align_to_top: bool) -> Result<(), ProviderError>
get_children
fn get_children(self: &Self) -> Result<Vec<Ref<AutomationPeer>>, ProviderError>
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.