---
title: textStyleRules
framework: avfoundation
role: symbol
role_heading: Instance Property
path: avfoundation/avplayeritem/textstylerules
---

# textStyleRules

An array of text style rules that specify the formatting and presentation of Web Video Text Tracks (WebVTT) subtitles.

## Declaration

```swift
nonisolated var textStyleRules: [AVTextStyleRule]? { get set }
```

## Discussion

Discussion Text style rules apply only to WebVTT subtitles. They don’t apply to other subtitle formats and legible text.

## See Also

### Accessing text style rules

- [AVTextStyleRule](avfoundation/avtextstylerule.md)
