---
title: TextFormattingCommands
framework: swiftui
role: symbol
role_heading: Structure
path: swiftui/textformattingcommands
---

# TextFormattingCommands

A built-in set of commands for transforming the styles applied to selections of text.

## Declaration

```swift
nonisolated struct TextFormattingCommands
```

## Mentioned in

Building and customizing the menu bar with SwiftUI

## Overview

Overview These commands are optional and can be explicitly requested by passing a value of this type to the Scene.commands(_:) modifier.

## Topics

### Creating the command group

- [init()](swiftui/textformattingcommands/init().md)

## Relationships

### Conforms To

- [Commands](swiftui/commands.md)

## See Also

### Getting built-in command groups

- [SidebarCommands](swiftui/sidebarcommands.md)
- [TextEditingCommands](swiftui/texteditingcommands.md)
- [ToolbarCommands](swiftui/toolbarcommands.md)
- [ImportFromDevicesCommands](swiftui/importfromdevicescommands.md)
- [InspectorCommands](swiftui/inspectorcommands.md)
- [EmptyCommands](swiftui/emptycommands.md)
