pub unsafe trait UITextSelectionHighlightView: UICoordinateSpace + MainThreadOnly {
// Provided methods
unsafe fn selectionRects(&self) -> Retained<NSArray<UITextSelectionRect>>
where Self: Sized + Message { ... }
unsafe 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§
Sourceunsafe fn selectionRects(&self) -> Retained<NSArray<UITextSelectionRect>>
Available on crate feature UITextInput only.
unsafe 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.
Sourceunsafe fn setSelectionRects(
&self,
selection_rects: &NSArray<UITextSelectionRect>,
)
Available on crate feature UITextInput only.
unsafe fn setSelectionRects( &self, selection_rects: &NSArray<UITextSelectionRect>, )
UITextInput only.Setter for selectionRects.