ITextProvider
trait · ferroui-controls · v0.5.0
trait ITextProvider
A portable text-pattern contract. Text offsets and maximum lengths use UTF-16
code units. Points and rectangles use the visual root's coordinate space, as
AutomationPeer::get_bounding_rectangle does; platform bridges convert to
native screen coordinates at their boundary.
Members
peerdocument_rangeget_selectionget_visible_rangesrange_from_childrange_from_pointsupported_text_selectiontext_changedtext_selection_changed
peer
fn peer(self: &Self) -> Ref<AutomationPeer>
document_range
fn document_range(self: &Self) -> Result<Rc<dyn ITextRangeProvider>, ProviderError>
get_selection
fn get_selection(self: &Self) -> Result<Vec<Rc<dyn ITextRangeProvider>>, ProviderError>
get_visible_ranges
fn get_visible_ranges(self: &Self) -> Result<Vec<Rc<dyn ITextRangeProvider>>, ProviderError>
range_from_child
fn range_from_child(self: &Self, child: &Ref<AutomationPeer>) -> Result<Rc<dyn ITextRangeProvider>, ProviderError>
range_from_point
fn range_from_point(self: &Self, point: Point) -> Result<Rc<dyn ITextRangeProvider>, ProviderError>
supported_text_selection
fn supported_text_selection(self: &Self) -> Result<SupportedTextSelection, ProviderError>
text_changed
fn text_changed(self: &Self, handler: Rc<dyn Fn() -> ()>) -> Result<Rc<dyn IDisposable>, ProviderError>
Observes content and formatting changes, including replacement of the document.
text_selection_changed
fn text_selection_changed(self: &Self, handler: Rc<dyn Fn() -> ()>) -> Result<Rc<dyn IDisposable>, ProviderError>
Observes changes to either selection endpoint, including the insertion point.
Trait implementations
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.