---
title: "convertInteractionPoint(_:toContainerAt:)"
framework: uikit
role: symbol
role_heading: Instance Method
platforms: [iOS 27.0+, iPadOS 27.0+, Mac Catalyst 27.0+, tvOS 27.0+, visionOS 27.0+]
path: "uikit/nstextselectiondatasource/convertinteractionpoint(_:tocontainerat:)"
---

# convertInteractionPoint(_:toContainerAt:)

Converts an interaction point from display space into the text container’s coordinate system.

## Declaration

```swift
optional func convertInteractionPoint(_ point: CGPoint, toContainerAt containerLocation: any NSTextLocation) -> CGPoint
```

## Parameters

- `point`: The interaction point in display/view-space coordinates.
- `containerLocation`: The location identifying the text container the interaction occurred in.

## Return Value

Return Value The point mapped into the text container’s coordinate system. Return point unchanged when no transform is active.

## Discussion

Discussion NSTextSelectionNavigation calls this method before hit-testing to allow the data source to undo any display transform (rotation, flip, path layout, etc.) applied to the text.
