decorate(foundTextRange:document:usingStyle:)
Applies the style to a specific text range to indicate found and highlighted results.
Declaration
func decorate(foundTextRange: UITextRange, document: Self.DocumentIdentifier?, usingStyle: UITextSearchFoundTextStyle)Parameters
- foundTextRange:
The text range to decorate.
- document:
A string that uniquely identifies the document containing the text range.
Nilwhen searching a single document. - usingStyle:
The style to decorate the text: highlighted, found, or normal.
Discussion
The system calls this method during a find session to display the results of a search in your custom view. Your implenentation should decorate matching text ranges for the given style to indicate the found and highlighted result.