---
title: textSelection
framework: visionkit
role: symbol
role_heading: Type Property
path: visionkit/imageanalysisinteraction/interactiontypes/textselection
---

# textSelection

An option that enables text selection, copying, and translating.

## Declaration

```swift
static let textSelection: ImageAnalysisInteraction.InteractionTypes
```

## Mentioned in

Enabling Live Text interactions with images

## Discussion

Discussion People can select text to perform actions. In this mode, the framework disables data detectors (dataDetectors) by default. However, if you set the allowLongPressForDataDetectorsInTextMode property to true, a person can use a long-press gesture to enable them.

## See Also

### Specifying types of interactions

- [automatic](visionkit/imageanalysisinteraction/interactiontypes/automatic.md)
- [dataDetectors](visionkit/imageanalysisinteraction/interactiontypes/datadetectors.md)
- [imageSubject](visionkit/imageanalysisinteraction/interactiontypes/imagesubject.md)
- [visualLookUp](visionkit/imageanalysisinteraction/interactiontypes/visuallookup.md)
- [automaticTextOnly](visionkit/imageanalysisinteraction/interactiontypes/automatictextonly.md)
