---
title: selectionRects
framework: uikit
role: symbol
role_heading: Instance Property
path: uikit/uitextselectionhighlightview/selectionrects
---

# selectionRects

The rectangles to draw with the selection highlight.

## Declaration

```swift
var selectionRects: [UITextSelectionRect] { get set }
```

## Discussion

Discussion Use this property to get the rectangles to draw in a custom highlight view. The rectangles are in the coordinate space of the view that adopts this protocol.
