---
title: "UIPointerShape.roundedRect(_:radius:)"
framework: uikit
role: symbol
role_heading: Case
path: "uikit/uipointershape-swift.enum/roundedrect(_:radius:)"
---

# UIPointerShape.roundedRect(_:radius:)

The pointer morphs into a rounded rectangle using the provided corner radius.

## Declaration

```swift
case roundedRect(CGRect, radius: CGFloat = UIPointerShape.defaultCornerRadius)
```

## Discussion

Discussion If you don’t specify a radius, the rounded rectangle uses the defaultCornerRadius. note: If used alongside a content effect, this rectangle must be in the view coordinate space of the preview. Otherwise, it’s centered around the pointer’s current location, and the rectangle’s origin is interpreted as an offset.

## See Also

### Specifying pointer shapes

- [UIPointerShape.horizontalBeam(length:)](uikit/uipointershape-swift.enum/horizontalbeam(length:).md)
- [UIPointerShape.verticalBeam(length:)](uikit/uipointershape-swift.enum/verticalbeam(length:).md)
- [UIPointerShape.path(_:)](uikit/uipointershape-swift.enum/path(_:).md)
