pub unsafe trait UITextSelectionHighlightView: UICoordinateSpace + MainThreadOnly {
// Provided methods
fn selectionRects(&self) -> Retained<NSArray<UITextSelectionRect>>
where Self: Sized + Message { ... }
fn setSelectionRects(&self, selection_rects: &NSArray<UITextSelectionRect>)
where Self: Sized + Message { ... }
}Available on crate features
UITextSelectionHighlightView and UIView only.Expand description
A view that displays a tinted highlight behind rendered text to indicate selection.
When a selection is ranged (i.e., length is > 0), a highlight view is shown to indicate the selected text range.
See also Apple’s documentation
Provided Methods§
Sourcefn selectionRects(&self) -> Retained<NSArray<UITextSelectionRect>>
Available on crate feature UITextInput only.
fn selectionRects(&self) -> Retained<NSArray<UITextSelectionRect>>
UITextInput only.A collection of
UITextSelectionRectsrepresenting the geometry of the current selection. Rects are expected to be in the
receiver’s coordinate space.
Sourcefn setSelectionRects(&self, selection_rects: &NSArray<UITextSelectionRect>)
Available on crate feature UITextInput only.
fn setSelectionRects(&self, selection_rects: &NSArray<UITextSelectionRect>)
UITextInput only.Setter for selectionRects.