enumerateContainerBoundaries(from:reverse:using:)
Enumerates all the container boundaries starting from the location you specify.
Declaration
optional func enumerateContainerBoundaries(from location: any NSTextLocation, reverse: Bool, using block: (any NSTextLocation, UnsafeMutablePointer<ObjCBool>) -> Void)Parameters
- location:
The location where the enumeration starts.
- reverse:
A Boolean value that indicates the enumeration starts at the end of the container.
- block:
A closure to invoke to evaluate the container boundaries; end the enumeration early by returning
false.
Discussion
This is an optional method you implement to enumerate the text up to the container or page boundary when the text selection data provider supports this layout functionality.