---
title: textAlignment
framework: vision
role: symbol
role_heading: Instance Property
path: vision/documentobservation/container/text-swift.struct/textalignment
---

# textAlignment

The alignment of the text within its container.

## Declaration

```swift
var textAlignment: DocumentObservation.Container.Text.Alignment? { get }
```

## See Also

### Inspecting the text

- [boundingRegion](vision/documentobservation/container/text-swift.struct/boundingregion.md)
- [DocumentObservation.Container.Text.Alignment](vision/documentobservation/container/text-swift.struct/alignment.md)
