---
title: "init(attributedText:)"
framework: uikit
role: symbol
role_heading: Initializer
path: "uikit/uisimpletextprintformatter/init(attributedtext:)"
---

# init(attributedText:)

Returns a simple-text print formatter initialized with attributed text.

## Declaration

```swift
init(attributedText: NSAttributedString)
```

## Parameters

- `attributedText`: A string of attributed text or nil if you intend to assign the text later.

## Return Value

Return Value An initialized instance of UISimpleTextPrintFormatter or nil if the object could not be created.

## See Also

### Related Documentation

- [attributedText](uikit/uisimpletextprintformatter/attributedtext.md)

### Creating a simple-text print formatter

- [init(text:)](uikit/uisimpletextprintformatter/init(text:).md)
